
package handling.channel.handler;


import client.*;
import client.inventory.*;
import client.skills.Skill;
import client.skills.SkillFactory;
import configs.ServerConfig;
import constants.GameConstants;
import constants.ItemConstants;
import constants.JobConstants;
import handling.world.WorldBroadcastService;
import handling.world.party.MaplePartyCharacter;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import scripting.item.ItemScriptManager;
import scripting.npc.NPCScriptManager;
import server.*;
import server.cashshop.CashItemFactory;
import server.life.MapleLifeFactory;
import server.life.MapleMonster;
import server.maps.*;
import server.quest.MapleQuest;
import server.shops.HiredMerchant;
import server.shops.IMaplePlayerShop;
import tools.DateUtil;
import tools.MaplePacketCreator;
import tools.Pair;
import tools.Randomizer;
import tools.data.input.LittleEndianAccessor;
import tools.packet.*;

import java.awt.*;
import java.util.*;
import java.util.List;
import java.util.concurrent.locks.Lock;
import java.util.stream.Collectors;


 public class InventoryHandler {
    /*   44 */   private static final Logger log = LogManager.getLogger("ItemLog");


       public static final int OWL_ID = 1;




    public static void ItemMove(LittleEndianAccessor slea, MapleClient c) {
        /*   51 */
        if (c.getPlayer() == null || c.getPlayer().hasBlockedInventory()) {

            return;

        }
        /*   54 */
        c.getPlayer().setScrolledPosition((short) 0);
        /*   55 */
        c.getPlayer().updateTick(slea.readInt());
        /*   56 */
        MapleInventoryType type = MapleInventoryType.getByType(slea.readByte());
        /*   57 */
        short src = slea.readShort();
        /*   58 */
        short dst = slea.readShort();
        /*   59 */
        short quantity = slea.readShort();
        /*   60 */
        if (src < 0 && dst > 0) {
            /*   61 */
            MapleInventoryManipulator.unequip(c, src, dst);
            /*   62 */
        } else if (dst < 0) {
            /*   63 */
            MapleInventoryManipulator.equip(c, src, dst);
            /*   64 */
        } else if (dst == 0) {
            /*   65 */
            MapleInventoryManipulator.drop(c, type, src, quantity);

        } else {
            /*   67 */
            MapleInventoryManipulator.move(c, type, src, dst);

        }

    }






    public static void SwitchBag(LittleEndianAccessor slea, MapleClient c) {
        /*   75 */
        if (c.getPlayer().hasBlockedInventory()) {

            return;

        }
        /*   78 */
        c.getPlayer().setScrolledPosition((short) 0);
        /*   79 */
        c.getPlayer().updateTick(slea.readInt());
        /*   80 */
        short src = (short) slea.readInt();
        /*   81 */
        short dst = (short) slea.readInt();
        /*   82 */
        if (src < 100 || dst < 100) {

            return;

        }
        /*   85 */
        MapleInventoryManipulator.move(c, MapleInventoryType.ETC, src, dst);

    }






    public static void MoveBag(LittleEndianAccessor slea, MapleClient c) {
        /*   92 */
        if (c.getPlayer().hasBlockedInventory()) {

            return;

        }
        /*   95 */
        c.getPlayer().setScrolledPosition((short) 0);
        /*   96 */
        c.getPlayer().updateTick(slea.readInt());
        /*   97 */
        boolean srcFirst = (slea.readInt() > 0);
        /*   98 */
        if (slea.readByte() != 4) {
            /*   99 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  102 */
        short dst = (short) slea.readInt();
        /*  103 */
        short src = slea.readShort();
        /*  104 */
        MapleInventoryManipulator.move(c, MapleInventoryType.ETC, srcFirst ? dst : src, srcFirst ? src : dst);

    }






    public static void ItemSort(LittleEndianAccessor slea, MapleClient c) {
        /*  111 */
        c.getPlayer().updateTick(slea.readInt());
        /*  112 */
        c.getPlayer().setScrolledPosition((short) 0);
        /*  113 */
        byte mode = slea.readByte();
        /*  114 */
        MapleInventoryType pInvType = MapleInventoryType.getByType(mode);
        /*  115 */
        if (pInvType == MapleInventoryType.UNDEFINED || c.getPlayer().hasBlockedInventory()) {
            /*  116 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  119 */
        MapleInventory pInv = c.getPlayer().getInventory(pInvType);
        /*  120 */
        boolean sorted = false;
        /*  121 */
        while (!sorted) {
            /*  122 */
            short freeSlot = pInv.getNextFreeSlot();
            /*  123 */
            if (freeSlot != -1) {
                /*  124 */
                short itemSlot = -1;
                short s1;
                /*  125 */
                for (s1 = (short) (freeSlot + 1); s1 <= pInv.getSlotLimit(); s1 = (short) (s1 + 1)) {
                    /*  126 */
                    if (pInv.getItem(s1) != null) {
                        /*  127 */
                        itemSlot = s1;

                        break;

                    }

                }
                /*  131 */
                if (itemSlot > 0) {
                    /*  132 */
                    MapleInventoryManipulator.move(c, pInvType, itemSlot, freeSlot);
                    continue;

                }
                /*  134 */
                sorted = true;

                continue;

            }
            /*  137 */
            sorted = true;

        }

        /*  140 */
        List<Item> itemMap = (List<Item>) pInv.list().stream().filter(item -> (item.getPosition() <= 128)).collect(Collectors.toCollection(LinkedList::new));
        /*  141 */
        itemMap.sort(Item::compareTo);
        /*  142 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();

        /*  144 */
        ArrayList<ModifyInventory> mods = new ArrayList<>();
        /*  145 */
        for (int i = 0; i < itemMap.size() - 1; i++) {
            /*  146 */
            int n = i;
            /*  147 */
            for (int j = i + 1; j < itemMap.size(); j++) {
                /*  148 */
                if (((Item) itemMap.get(j)).getItemId() < ((Item) itemMap.get(n)).getItemId()) {
                    /*  149 */
                    n = j;

                }

            }
            /*  152 */
            if (n != i) {
                /*  153 */
                Item item = itemMap.get(i);
                /*  154 */
                short position = item.getPosition();
                /*  155 */
                pInv.move(position, ((Item) itemMap.get(n)).getPosition(), ii.getSlotMax(item.getItemId()));
                /*  156 */
                mods.add(new ModifyInventory(2, item, position));
                /*  157 */
                itemMap.set(i, itemMap.get(n));
                /*  158 */
                itemMap.set(n, item);

            }

        }

        /*  162 */
        itemMap.clear();
        /*  163 */
        c.announce(InventoryPacket.modifyInventory(true, mods, c.getPlayer()));
        /*  164 */
        c.announce(MaplePacketCreator.finishedSort(mode));
        /*  165 */
        c.announce(MaplePacketCreator.enableActions());

    }






    public static void ItemGather(LittleEndianAccessor slea, MapleClient c) {
        /*  172 */
        c.getPlayer().updateTick(slea.readInt());
        /*  173 */
        c.getPlayer().setScrolledPosition((short) 0);
        /*  174 */
        if (c.getPlayer().hasBlockedInventory()) {
            /*  175 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  178 */
        byte mode = slea.readByte();
        /*  179 */
        MapleInventoryType invType = MapleInventoryType.getByType(mode);
        /*  180 */
        MapleInventory Inv = c.getPlayer().getInventory(invType);

        /*  182 */
        List<Item> itemMap = (List<Item>) Inv.list().stream().filter(item -> (item.getPosition() <= 128)).collect(Collectors.toCollection(LinkedList::new));
        /*  183 */
        itemMap.sort(Item::compareTo);

        /*  185 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /*  186 */
        Map<Integer, List<Item>> needGathers = new LinkedHashMap<>();
        /*  187 */
        itemMap.forEach(item -> {

            List<Item> items = Inv.listById(item.getItemId());


            if (items.size() > 1) {

                needGathers.put(Integer.valueOf(item.getItemId()), items);

            }

        });
        /*  194 */
        ArrayList<ModifyInventory> mods = new ArrayList<>();

        /*  196 */
        for (List<Item> items : needGathers.values()) {
            /*  197 */
            int i = 0;
            /*  198 */
            Item target = items.get(i);
            /*  199 */
            short slotMax = ii.getSlotMax(target.getItemId());
            /*  200 */
            for (int j = items.size() - 1; j >= i; j--) {
                /*  201 */
                Item item = items.get(j);
                /*  202 */
                if (target != item) {
                    /*  203 */
                    if (item.getQuantity() >= slotMax) {
                        /*  204 */
                        Inv.swap(item, target);
                        /*  205 */
                        mods.add(new ModifyInventory(1, item, item.getPosition()));

                    } else {
                        /*  207 */
                        Inv.move(item.getPosition(), target.getPosition(), slotMax);
                        /*  208 */
                        if (Inv.getItem(item.getPosition()) != null) {
                            /*  209 */
                            j++;
                            /*  210 */
                            i++;
                            /*  211 */
                            if (i == items.size()) {

                                break;

                            }
                            /*  214 */
                            target = items.get(i);

                        } else {
                            /*  216 */
                            mods.add(new ModifyInventory(3, item, item.getPosition()));

                        }

                    }

                }

            }
            /*  221 */
            mods.add(new ModifyInventory(1, target, target.getPosition()));

        }
        /*  223 */
        c.announce(InventoryPacket.modifyInventory(true, mods, c.getPlayer()));
        /*  224 */
        c.announce(MaplePacketCreator.finishedGather(mode));
        /*  225 */
        c.announce(MaplePacketCreator.enableActions());
        /*  226 */
        itemMap.clear();
        /*  227 */
        needGathers.clear();
        /*  228 */
        mods.clear();

    }



    public static boolean UseRewardBox(short slot, int itemId, MapleClient c, MapleCharacter player) {
        /*  232 */
        Item toUse = c.getPlayer().getInventory(ItemConstants.getInventoryType(itemId)).getItem(slot);
        /*  233 */
        c.sendEnableActions();
        /*  234 */
        if (toUse != null && toUse.getQuantity() >= 1 && toUse.getItemId() == itemId && !player.hasBlockedInventory()) {
            /*  235 */
            if (player.getInventory(MapleInventoryType.EQUIP).getNextFreeSlot() > -1 && player.getInventory(MapleInventoryType.USE).getNextFreeSlot() > -1 && player.getInventory(MapleInventoryType.SETUP).getNextFreeSlot() > -1 && player.getInventory(MapleInventoryType.ETC).getNextFreeSlot() > -1) {
                /*  236 */
                List<Pair<Integer, Integer>> list = CashItemFactory.getInstance().getRandomItem(itemId);
                /*  237 */
                if (list != null && list.size() > 0) {
                    /*  238 */
                    int nextInt = Randomizer.nextInt(list.size());
                    /*  239 */
                    int itemSN = ((Integer) ((Pair) list.get(nextInt)).getLeft()).intValue();
                    /*  240 */
                    int quantity = ((Integer) ((Pair) list.get(nextInt)).getRight()).intValue();
                    /*  241 */
                    int rewardItemId = CashItemFactory.getInstance().getItem(itemSN).getItemId();
                    /*  242 */
                    if (player.isAdmin()) {
                        /*  243 */
                        player.dropMessage(5, "打开道具获得: " + rewardItemId);

                    }
                    /*  245 */
                    MapleInventoryManipulator.addById(c, rewardItemId, (short) quantity, "打开随机箱子 道具ID: " + itemId + " 时间: " + DateUtil.getNowTime());
                    /*  246 */
                    c.announce(MaplePacketCreator.getShowItemGain(rewardItemId, (short) 1, true));
                    /*  247 */
                    MapleInventoryManipulator.removeFromSlot(c, ItemConstants.getInventoryType(itemId), slot, (short) 1, false);
                    /*  248 */
                    return true;

                }
                /*  250 */
                player.dropMessage(6, "出现未知错误.");

            } else {
                /*  252 */
                player.dropMessage(6, "背包空间不足。");

            }

        }
        /*  255 */
        return false;

    }



    public static boolean UseRewardItem(short slot, int itemId, MapleClient c, MapleCharacter chr) {
        /*  259 */
        Item toUse = c.getPlayer().getInventory(ItemConstants.getInventoryType(itemId)).getItem(slot);
        /*  260 */
        c.sendEnableActions();
        /*  261 */
        if (toUse != null && toUse.getQuantity() >= 1 && toUse.getItemId() == itemId && !chr.hasBlockedInventory()) {
            /*  262 */
            if (chr.getInventory(MapleInventoryType.EQUIP).getNextFreeSlot() > -1 && chr.getInventory(MapleInventoryType.USE).getNextFreeSlot() > -1 && chr.getInventory(MapleInventoryType.SETUP).getNextFreeSlot() > -1 && chr.getInventory(MapleInventoryType.ETC).getNextFreeSlot() > -1) {
                /*  263 */
                MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
                /*  264 */
                if (itemId == 2028048) {
                    /*  265 */
                    int mesars = 5000000;
                    /*  266 */
                    if (mesars > 0 && chr.getMeso() < (Integer.MAX_VALUE - mesars)) {
                        /*  267 */
                        int gainmes = Randomizer.nextInt(mesars);
                        /*  268 */
                        chr.gainMeso(gainmes, true, true);
                        /*  269 */
                        c.announce(MTSCSPacket.INSTANCE.sendMesobagSuccess(gainmes));

                        /*  271 */
                        MapleInventoryManipulator.removeFromSlot(c, ItemConstants.getInventoryType(itemId), slot, (short) 1, false);
                        /*  272 */
                        return true;

                    }
                    /*  274 */
                    chr.dropMessage(1, "金币已达到上限无法使用这个道具.");
                    /*  275 */
                    return false;

                }

                /*  278 */
                Pair<Integer, List<Map<String, String>>> rewards = ii.getRewardItem(itemId);

                /*  280 */
                if (rewards != null && ((Integer) rewards.getLeft()).intValue() > 0) {

                    while (true) {
                        /*  282 */
                        for (Map<String, String> reward : (Iterable<Map<String, String>>) rewards.getRight()) {
                            /*  283 */
                            int rewardItemId = Integer.valueOf(reward.get("item")).intValue();
                            /*  284 */
                            int prob = Integer.valueOf(reward.get("prob")).intValue();
                            /*  285 */
                            short quantity = Short.valueOf(reward.get("count")).shortValue();
                            /*  286 */
                            int period = Integer.valueOf((reward.get("period") != null) ? reward.get("period") : "0").intValue();
                            /*  287 */
                            String effect = reward.get("effect");
                            /*  288 */
                            String worldmsg = reward.get("worldmsg");
                            /*  289 */
                            if (prob > 0 && Randomizer.nextInt(((Integer) rewards.getLeft()).intValue()) < prob) {
                                /*  290 */
                                if (ItemConstants.getInventoryType(rewardItemId) == MapleInventoryType.EQUIP) {
                                    /*  291 */
                                    Item item = ii.getEquipById(rewardItemId);
                                    /*  292 */
                                    if (rewardItemId > 0) {
                                        /*  293 */
                                        item.setExpiration(System.currentTimeMillis() + (period * 60 * 1000));

                                    }
                                    /*  295 */
                                    item.setGMLog("Reward item: " + itemId + " on " + DateUtil.getCurrentDate());
                                    /*  296 */
                                    if (chr.isAdmin()) {
                                        /*  297 */
                                        chr.dropMessage(5, "打开道具获得: " + item.getItemId());

                                    }
                                    /*  299 */
                                    if (rewardItemId / 1000 == 1182) {
                                        /*  300 */
                                        ii.randomize休彼德蔓徽章((Equip) item);

                                    }
                                    /*  302 */
                                    MapleInventoryManipulator.addbyItem(c, item);
                                    /*  303 */
                                    c.announce(MaplePacketCreator.getShowItemGain(item.getItemId(), item.getQuantity(), true));

                                } else {
                                    /*  305 */
                                    if (chr.isAdmin()) {
                                        /*  306 */
                                        chr.dropMessage(5, "打开道具获得: " + rewardItemId + " - " + quantity);

                                    }
                                    /*  308 */
                                    MapleInventoryManipulator.addById(c, rewardItemId, quantity, "Reward item: " + itemId + " on " + DateUtil.getCurrentDate());
                                    /*  309 */
                                    c.announce(MaplePacketCreator.getShowItemGain(rewardItemId, quantity, true));

                                }

                                /*  312 */
                                MapleInventoryManipulator.removeFromSlot(c, ItemConstants.getInventoryType(itemId), slot, (short) 1, false);
                                /*  313 */
                                c.announce(EffectPacket.showRewardItemAnimation(rewardItemId, effect));
                                /*  314 */
                                chr.getMap().broadcastMessage(chr, EffectPacket.showRewardItemAnimation(rewardItemId, effect, chr.getId()), false);
                                /*  315 */
                                return true;

                            }

                        }

                    }

                }
                /*  320 */
                chr.dropMessage(6, "出现未知错误.");

            } else {

                /*  323 */
                chr.dropMessage(6, "背包空间不足。");

            }

        }
        /*  326 */
        return false;

    }






    public static void UseItem(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /*  333 */
        if (chr == null || !chr.isAlive() || chr.getMapId() == 749040100 || chr.getMap() == null || chr.hasDisease(MapleDisease.无法使用药水) || chr.hasBlockedInventory() || chr.inPVP() || chr.getMap().isPvpMaps()) {
            /*  334 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  337 */
        long time = System.currentTimeMillis();
        /*  338 */
        if (chr.getNextConsume() > time) {
            /*  339 */
            chr.dropMessage(5, "暂时无法使用这个道具，请稍后在试。");
            /*  340 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  343 */
        c.getPlayer().updateTick(slea.readInt());
        /*  344 */
        short slot = slea.readShort();
        /*  345 */
        int itemId = slea.readInt();
        /*  346 */
        Item toUse = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /*  347 */
        if (toUse == null || toUse.getQuantity() < 1 || toUse.getItemId() != itemId) {
            /*  348 */
            c.announce(MaplePacketCreator.enableActions());


            return;

        }
        /*  352 */
        if (!FieldLimitType.PotionUse.check(chr.getMap().getFieldLimit())) {
            /*  353 */
            if (MapleItemInformationProvider.getInstance().getItemEffect(toUse.getItemId()).applyTo(chr)) {
                /*  354 */
                MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                /*  355 */
                if (chr.getMap().getConsumeItemCoolTime() > 0) {
                    /*  356 */
                    chr.setNextConsume(time + (chr.getMap().getConsumeItemCoolTime() * 1000));

                }

            }

        } else {
            /*  360 */
            c.announce(MaplePacketCreator.enableActions());

        }

    }






    public static void UseCosmetic(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /*  368 */
        if (chr == null || !chr.isAlive() || chr.getMap() == null || chr.hasBlockedInventory() || chr.inPVP()) {
            /*  369 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  372 */
        short slot = slea.readShort();
        /*  373 */
        int itemId = slea.readInt();
        /*  374 */
        Item toUse = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /*  375 */
        if (toUse == null || toUse.getQuantity() < 1 || toUse.getItemId() != itemId || itemId / 10000 != 254 || itemId / 1000 % 10 != chr.getGender()) {
            /*  376 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  379 */
        if (MapleItemInformationProvider.getInstance().getItemEffect(toUse.getItemId()).applyTo(chr)) {
            /*  380 */
            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);

        }

    }








































    public static void UseReducer(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /*  422 */
        if (chr == null || !chr.isAlive() || chr.getMap() == null || chr.hasBlockedInventory() || chr.inPVP()) {
            /*  423 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  426 */
        int itemId = slea.readInt();
        /*  427 */
        byte slot = (byte) slea.readInt();
        /*  428 */
        Item toUse = chr.getInventory(MapleInventoryType.USE).getItem((short) slot);
        /*  429 */
        if (toUse == null || toUse.getQuantity() < 1 || toUse.getItemId() != itemId || itemId / 1000 != 2702) {
            /*  430 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  433 */
        chr.renewInnerSkills(itemId);
        /*  434 */
        chr.equipChanged();
        /*  435 */
        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, toUse.getPosition(), (short) 1, false);
        /*  436 */
        c.announce(MaplePacketCreator.enableActions());

    }























































    public static void UseReducerPrestige(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /*  492 */
        if (chr == null || !chr.isAlive() || chr.getMap() == null || chr.hasBlockedInventory() || chr.inPVP()) {
            /*  493 */
            c.announce(MaplePacketCreator.enableActions());


            return;

        }
        /*  497 */
        boolean isLock = (slea.readInt() > 0);

        /*  499 */
        int lockCount = slea.readInt();


        /*  502 */
        List<Integer> lockLine = new ArrayList<>();
        /*  503 */
        for (int i = 0; i < lockCount; i++)
             {
            /*  505 */
            lockLine.add(Integer.valueOf(slea.readInt()));

        }

        /*  508 */
        int needHonor = 100;

        /*  510 */
        int rank = chr.getInnerRank();

        /*  512 */
        if (isLock) {
            /*  513 */
            needHonor = ItemConstants.getNeedHonor(lockLine, needHonor, rank);

        }

        /*  516 */
        if (chr.getHonor() < needHonor || (isLock && (rank < 1 || lockLine.size() > 2))) {
            /*  517 */
            c.announce(MaplePacketCreator.enableActions());


            return;

        }
        /*  521 */
        chr.renewInnerSkills(isLock ? -2 : 0, lockLine);


        /*  524 */
        chr.gainHonor(chr.isAdmin() ? 0 : -needHonor);
        /*  525 */
        chr.equipChanged();
        /*  526 */
        chr.dropMessage(1, "能力重新设置成功");
        /*  527 */
        c.announce(MaplePacketCreator.enableActions());

    }






    public static void UseReturnScroll(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /*  534 */
        if (!chr.isAlive() || chr.getMapId() == 749040100 || chr.hasBlockedInventory() || chr.isInBlockedMap() || chr.inPVP()) {
            /*  535 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  538 */
        c.getPlayer().updateTick(slea.readInt());
        /*  539 */
        short slot = slea.readShort();
        /*  540 */
        int itemId = slea.readInt();
        /*  541 */
        Item toUse = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /*  542 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /*  543 */
        if (toUse == null || toUse.getQuantity() < 1 || toUse.getItemId() != itemId) {
            /*  544 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  547 */
        if (!FieldLimitType.PotionUse.check(chr.getMap().getFieldLimit())) {
            /*  548 */
            if (ii.getItemEffect(toUse.getItemId()).applyReturnScroll(chr)) {
                /*  549 */
                MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);

            } else {
                /*  551 */
                c.announce(MaplePacketCreator.enableActions());

            }

        } else {
            /*  554 */
            c.announce(MaplePacketCreator.enableActions());

        }

    }



    public static void UseMiracleCube(LittleEndianAccessor slea, MapleCharacter chr) {
        /*  559 */
        chr.updateTick(slea.readInt());
        /*  560 */
        short scrollSlot = slea.readShort();
        /*  561 */
        Item cube = chr.getInventory(MapleInventoryType.USE).getItem(scrollSlot);
        /*  562 */
        short toScrollSlot = slea.readShort();
        /*  563 */
        Equip toScroll = (Equip) chr.getInventory(MapleInventoryType.EQUIP).getItem(toScrollSlot);
        /*  564 */
        if (cube == null || toScroll == null) {

            return;

        }
        /*  567 */
        boolean bl2 = toScroll.resetPotential(cube.getItemId(), chr, 0, (short) 0);
        /*  568 */
        if (bl2) {
            /*  569 */
            chr.forceUpdateItem((Item) toScroll);
            /*  570 */
            MapleInventoryManipulator.removeFromSlot(chr.getClient(), MapleInventoryType.USE, scrollSlot, (short) 1, false, true);

        }
        /*  572 */
        chr.sendEnableActions();

    }





    public static void UseMagnify(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {

        Equip toScroll;
        /*  579 */
        chr.updateTick(slea.readInt());
        /*  580 */
        chr.setScrolledPosition((short) 0);
        /*  581 */
        byte src = (byte) slea.readShort();
        /*  582 */
        byte dst = (byte) slea.readShort();
        /*  583 */
        boolean insight = (src == Byte.MAX_VALUE);
        /*  584 */
        Item magnify = chr.getInventory(MapleInventoryType.USE).getItem((short) src);
        /*  585 */
        if (magnify == null || src == 32) {
            /*  586 */
            magnify = new Item();
            /*  587 */
            magnify.setItemId(2460005);

        }


        /*  591 */
        if (dst < 0) {
            /*  592 */
            toScroll = (Equip) chr.getInventory(MapleInventoryType.EQUIPPED).getItem((short) dst);

        } else {
            /*  594 */
            toScroll = (Equip) chr.getInventory(MapleInventoryType.EQUIP).getItem((short) dst);

        }
        /*  596 */
        if (chr.isShowPacket()) {
            /*  597 */
            chr.dropMessage(5, "鉴定装备: 放大镜: " + magnify + " insight: " + insight + " toScroll: " + toScroll + " BlockedInventory: " + c.getPlayer().hasBlockedInventory());

        }
        /*  599 */
        if ((magnify == null && !insight) || toScroll == null || c.getPlayer().hasBlockedInventory()) {
            /*  600 */
            chr.dropMessage(5, "现在还不能进行操作。");
            /*  601 */
            c.announce(InventoryPacket.getInventoryFull());

            return;

        }
        /*  604 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /*  605 */
        int reqLevel = ii.getReqLevel(toScroll.getItemId()) / 10;
        /*  606 */
        int n3 = (reqLevel >= 20) ? 19 : reqLevel;
        /*  607 */
        if (((toScroll.getState(false) < 17 && toScroll.getState(false) > 0) || (toScroll.getState(true) < 17 && toScroll.getState(true) > 0)) && (insight || magnify.getItemId() == 2460005 || magnify.getItemId() == 2460004 || magnify.getItemId() == 2460003 || (magnify.getItemId() == 2460002 && n3 <= 12) || (magnify.getItemId() == 2460001 && n3 <= 7) || (magnify.getItemId() == 2460000 && n3 <= 3))) {
            /*  608 */
            boolean isPotAdd = (toScroll.getState(false) < 17 && toScroll.getState(false) > 0);
            /*  609 */
            if (insight) {
                /*  610 */
                long meso = ItemConstants.getCubeNeedMeso(toScroll);
                /*  611 */
                if (chr.getMeso() < meso) {
                    /*  612 */
                    chr.dropMessage(5, "您没有足够的金币。");
                    /*  613 */
                    c.sendEnableActions();

                    return;

                }
                /*  616 */
                chr.gainMeso(-meso, false);

            }
            /*  618 */
            Equip nEquip = ItemScrollHandler.ItemPotentialAndMagnify(toScroll, chr, false);
            /*  619 */
            if (ItemConstants.isZeroWeapon(nEquip.getItemId())) {
                /*  620 */
                dst = (byte) ((dst == -10) ? -11 : -10);
                /*  621 */
                chr.forceUpdateItem((Item) ((Equip) chr.getInventory(MapleInventoryType.EQUIPPED).getItem((short) dst)).copyPotential(nEquip), true);

            }
            /*  623 */
            chr.getTrait(MapleTraitType.insight).addExp((insight ? 10 : (magnify.getItemId() + 2 - 2460000)) * 2, chr);
            /*  624 */
            chr.getMap().broadcastMessage(InventoryPacket.showMagnifyingEffect(chr.getId(), toScroll.getPosition(), !isPotAdd));
            /*  625 */
            if (!insight) {
                /*  626 */
                MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, magnify.getPosition(), (short) 1, false);

            }
            /*  628 */
            chr.forceUpdateItem((Item) toScroll, true);
            /*  629 */
            if (dst < 0) {
                /*  630 */
                chr.equipChanged();

            }
            /*  632 */
            c.announce(MaplePacketCreator.enableActions());

        } else {
            /*  634 */
            c.announce(InventoryPacket.getInventoryFull());

        }

    }






    public static boolean UseSkillBook(short slot, int itemId, MapleClient c, MapleCharacter chr) {
        /*  642 */
        Item toUse = chr.getInventory(ItemConstants.getInventoryType(itemId)).getItem(slot);
        /*  643 */
        if (toUse == null || toUse.getQuantity() < 1 || toUse.getItemId() != itemId || chr.hasBlockedInventory()) {
            /*  644 */
            return false;

        }
        /*  646 */
        Map<String, Integer> skilldata = MapleItemInformationProvider.getInstance().getItemBaseInfo(toUse.getItemId());
        /*  647 */
        Map<String, Integer> skillids = MapleItemInformationProvider.getInstance().getBookSkillID(toUse.getItemId());
        /*  648 */
        if (skilldata == null) {
            /*  649 */
            return false;

        }
        /*  651 */
        boolean canuse = false, success = false;
        /*  652 */
        int skill = 0, maxlevel = 0;

        /*  654 */
        Integer SuccessRate = skilldata.get("success");
        /*  655 */
        Integer ReqSkillLevel = skilldata.get("reqSkillLevel");
        /*  656 */
        Integer MasterLevel = skilldata.get("masterLevel");

        /*  658 */
        int i = 0;


        while (true) {
            /*  661 */
            Integer CurrentLoopedSkillId = skillids.get(String.valueOf(i));
            /*  662 */
            i++;
            /*  663 */
            if (CurrentLoopedSkillId == null || MasterLevel == null) {

                break;

            }
            /*  666 */
            Skill CurrSkillData = SkillFactory.getSkill(CurrentLoopedSkillId.intValue());
            /*  667 */
            if (CurrSkillData != null && CurrSkillData.canBeLearnedBy(chr.getJob()) && (ReqSkillLevel == null || chr.getSkillLevel(CurrSkillData) >= ReqSkillLevel.intValue()) && chr.getMasterLevel(CurrSkillData) < MasterLevel.intValue()) {
                /*  668 */
                canuse = true;
                /*  669 */
                if (SuccessRate == null || Randomizer.nextInt(100) <= SuccessRate.intValue()) {
                    /*  670 */
                    success = true;
                    /*  671 */
                    chr.changeSingleSkillLevel(CurrSkillData, chr.getSkillLevel(CurrSkillData), (byte) MasterLevel.intValue());

                } else {
                    /*  673 */
                    success = false;

                }
                /*  675 */
                MapleInventoryManipulator.removeFromSlot(c, ItemConstants.getInventoryType(itemId), slot, (short) 1, false);

                break;

            }

        }
        /*  679 */
        c.getPlayer().getMap().broadcastMessage(MaplePacketCreator.useSkillBook(chr, skill, maxlevel, canuse, success));
        /*  680 */
        c.announce(MaplePacketCreator.enableActions());
        /*  681 */
        return canuse;

    }






    public static void UseSpReset(short slot, int itemId, MapleClient c, MapleCharacter chr) {
        /*  688 */
        Item toUse = chr.getInventory(ItemConstants.getInventoryType(itemId)).getItem(slot);
        /*  689 */
        if (toUse == null || itemId / 1000 != 2500 || toUse.getItemId() != itemId || JobConstants.is新手职业(chr.getJob())) {
            /*  690 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  693 */
        chr.spReset();
        /*  694 */
        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, true);
        /*  695 */
        c.announce(MaplePacketCreator.useSPReset(chr.getId()));

    }






    public static void UseApReset(short slot, int itemId, MapleClient c, MapleCharacter chr) {
        /*  702 */
        Item toUse = chr.getInventory(ItemConstants.getInventoryType(itemId)).getItem(slot);
        /*  703 */
        if (toUse != null && toUse.getQuantity() > 0 && toUse.getItemId() == itemId && !chr.hasBlockedInventory() && itemId / 10000 == 250) {
            /*  704 */
            chr.resetStats(4, 4, 4, 4);
            /*  705 */
            MapleInventoryManipulator.removeFromSlot(c, ItemConstants.getInventoryType(itemId), slot, (short) 1, false);
            /*  706 */
            c.announce(MaplePacketCreator.useAPReset(chr.getId()));
            /*  707 */
            c.announce(MaplePacketCreator.enableActions());

        } else {
            /*  709 */
            c.announce(MaplePacketCreator.enableActions());

        }

    }






    public static void UseCatchItem(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /*  717 */
        c.getPlayer().updateTick(slea.readInt());
        /*  718 */
        c.getPlayer().setScrolledPosition((short) 0);
        /*  719 */
        short slot = slea.readShort();
        /*  720 */
        int itemid = slea.readInt();
        /*  721 */
        MapleMonster mob = chr.getMap().getMonsterByOid(slea.readInt());
        /*  722 */
        Item toUse = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /*  723 */
        MapleMap map = chr.getMap();
        /*  724 */
        if (toUse != null && toUse.getQuantity() > 0 && toUse.getItemId() == itemid && mob != null && !chr.hasBlockedInventory() && itemid / 10000 == 227 && MapleItemInformationProvider.getInstance().getCardMobId(itemid) == mob.getId()) {
            /*  725 */
            if (!MapleItemInformationProvider.getInstance().isMobHP(itemid) || mob.getHp() <= mob.getMobMaxHp() / 2L) {
                /*  726 */
                map.broadcastMessage(MobPacket.catchMonster(mob.getObjectId(), itemid, (byte) 1));
                /*  727 */
                map.killMonster(mob, chr, true, false, (byte) 1);
                /*  728 */
                MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false, false);
                /*  729 */
                if (MapleItemInformationProvider.getInstance().getCreateId(itemid) > 0) {
                    /*  730 */
                    MapleInventoryManipulator.addById(c, MapleItemInformationProvider.getInstance().getCreateId(itemid), (short) 1, "Catch item " + itemid + " on " + DateUtil.getCurrentDate());

                }

            } else {
                /*  733 */
                map.broadcastMessage(MobPacket.catchMonster(mob.getObjectId(), itemid, (byte) 0));

            }

        }
        /*  736 */
        c.announce(MaplePacketCreator.enableActions());

    }






    public static void UseMountFood(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /*  743 */
        c.getPlayer().updateTick(slea.readInt());
        /*  744 */
        short slot = slea.readShort();
        /*  745 */
        int itemid = slea.readInt();
        /*  746 */
        Item toUse = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /*  747 */
        MapleMount mount = chr.getMount();
        /*  748 */
        if (itemid / 10000 == 226 && toUse != null && toUse.getQuantity() > 0 && toUse.getItemId() == itemid && mount != null && !c.getPlayer().hasBlockedInventory()) {
            /*  749 */
            int fatigue = mount.getFatigue();
            /*  750 */
            boolean levelup = false;
            /*  751 */
            mount.setFatigue((byte) -30);
            /*  752 */
            if (fatigue > 0) {
                /*  753 */
                mount.increaseExp();
                /*  754 */
                int level = mount.getLevel();
                /*  755 */
                if (level < 30 && mount.getExp() >= GameConstants.getMountExpNeededForLevel(level + 1)) {
                    /*  756 */
                    mount.setLevel((byte) (level + 1));
                    /*  757 */
                    levelup = true;

                }

            }
            /*  760 */
            chr.getMap().broadcastMessage(MaplePacketCreator.updateMount(chr, levelup));
            /*  761 */
            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);

        }
        /*  763 */
        c.announce(MaplePacketCreator.enableActions());

    }



    public static void UseScriptedNPCItem(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /*  767 */
        if (c == null || chr == null) {

            return;

        }
        /*  770 */
        c.getPlayer().updateTick(slea.readInt());
        /*  771 */
        short slot = slea.readShort();
        /*  772 */
        int itemId = slea.readInt();
        /*  773 */
        Item toUse = chr.getInventory(ItemConstants.getInventoryType(itemId)).getItem(slot);
        /*  774 */
        long expiration_days = 0L;
        /*  775 */
        int mountid = 0;
        /*  776 */
        int damageSkin = -1;
        /*  777 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /*  778 */
        ScriptedItem info = ii.getScriptedItemInfo(itemId);
        /*  779 */
        if (info == null) {
            /*  780 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /*  783 */
        if (toUse != null && toUse.getQuantity() >= 1 && toUse.getItemId() == itemId && !chr.hasBlockedInventory() && !chr.inPVP()) {
            /*  784 */
            MapleInventory inventory;
            int hair;
            MapleQuestStatus marr;
            boolean warped;
            long lastTime;
            int i;
            int itemid;
            switch (toUse.getItemId()) {

                case 2430007:
                    /*  786 */
                    inventory = chr.getInventory(MapleInventoryType.SETUP);
                    /*  787 */
                    MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                    /*  788 */
                    if (inventory.countById(3994102) >= 20 && inventory
/*  789 */.countById(3994103) >= 20 && inventory
/*  790 */.countById(3994104) >= 20 && inventory
/*  791 */.countById(3994105) >= 20) {

                        /*  793 */
                        MapleInventoryManipulator.addById(c, 2430008, (short) 1, "Scripted item: " + itemId + " on " + DateUtil.getCurrentDate());
                        /*  794 */
                        MapleInventoryManipulator.removeById(c, MapleInventoryType.SETUP, 3994102, 20, false, false);
                        /*  795 */
                        MapleInventoryManipulator.removeById(c, MapleInventoryType.SETUP, 3994103, 20, false, false);
                        /*  796 */
                        MapleInventoryManipulator.removeById(c, MapleInventoryType.SETUP, 3994104, 20, false, false);
                        /*  797 */
                        MapleInventoryManipulator.removeById(c, MapleInventoryType.SETUP, 3994105, 20, false, false);

                    } else {

                        /*  800 */
                        MapleInventoryManipulator.addById(c, 2430007, (short) 1, "Scripted item: " + itemId + " on " + DateUtil.getCurrentDate());

                    }
                    /*  802 */
                    NPCScriptManager.getInstance().start(c, 2084001);

                    break;


                case 2430008:
                    /*  806 */
                    chr.saveLocation(SavedLocationType.RICHIE);

                    /*  808 */
                    warped = false;
                    /*  809 */
                    for (i = 390001000; i <= 390001004; i++) {
                        /*  810 */
                        MapleMap map = c.getChannelServer().getMapFactory().getMap(i);
                        /*  811 */
                        if (map.getCharactersSize() == 0) {
                            /*  812 */
                            chr.changeMap(map, map.getPortal(0));
                            /*  813 */
                            warped = true;

                            break;

                        }

                    }
                    /*  817 */
                    if (warped) {
                        /*  818 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                        break;

                    }
                    /*  820 */
                    c.getPlayer().dropMessage(5, "All maps are currently in use, please try again later.");

                    break;



                case 2430112:
                    /*  825 */
                    if (c.getPlayer().getInventory(MapleInventoryType.USE).getNumFreeSlot() >= 1) {
                        /*  826 */
                        if (c.getPlayer().getInventory(MapleInventoryType.USE).countById(2430112) >= 25) {
                            /*  827 */
                            if (MapleInventoryManipulator.checkSpace(c, 2049400, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 25, true, false)) {
                                /*  828 */
                                MapleInventoryManipulator.addById(c, 2049400, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /*  830 */
                            c.getPlayer().dropMessage(5, "消耗栏空间位置不足.");
                            break;

                        }
                        /*  832 */
                        if (c.getPlayer().getInventory(MapleInventoryType.USE).countById(2430112) >= 10) {
                            /*  833 */
                            if (MapleInventoryManipulator.checkSpace(c, 2049401, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 10, true, false)) {
                                /*  834 */
                                MapleInventoryManipulator.addById(c, 2049401, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /*  836 */
                            c.getPlayer().dropMessage(5, "消耗栏空间位置不足.");

                            break;

                        }
                        /*  839 */
                        ItemScriptManager.getInstance().start(c, info.getNpc(), toUse);


                        break;

                    }
                    /*  843 */
                    c.getPlayer().dropMessage(5, "消耗栏空间位置不足.");

                    break;


                case 2430481:
                    /*  847 */
                    if (c.getPlayer().getInventory(MapleInventoryType.USE).getNumFreeSlot() >= 1) {
                        /*  848 */
                        if (c.getPlayer().getInventory(MapleInventoryType.USE).countById(2430481) >= 100) {
                            /*  849 */
                            if (MapleInventoryManipulator.checkSpace(c, 2049701, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 100, true, false)) {
                                /*  850 */
                                MapleInventoryManipulator.addById(c, 2049701, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /*  852 */
                            c.getPlayer().dropMessage(5, "消耗栏空间位置不足.");
                            break;

                        }
                        /*  854 */
                        if (c.getPlayer().getInventory(MapleInventoryType.USE).countById(2430481) >= 30) {
                            /*  855 */
                            if (MapleInventoryManipulator.checkSpace(c, 2049400, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 30, true, false)) {
                                /*  856 */
                                MapleInventoryManipulator.addById(c, 2049400, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /*  858 */
                            c.getPlayer().dropMessage(5, "消耗栏空间位置不足.");

                            break;

                        }
                        /*  861 */
                        ItemScriptManager.getInstance().start(c, info.getNpc(), toUse);

                        break;

                    }
                    /*  864 */
                    c.getPlayer().dropMessage(5, "消耗栏空间位置不足.");

                    break;


                case 2430760:
                    /*  868 */
                    if (c.getPlayer().getInventory(MapleInventoryType.CASH).getNumFreeSlot() >= 1) {
                        /*  869 */
                        if (c.getPlayer().getInventory(MapleInventoryType.USE).countById(2430760) >= 10) {
                            /*  870 */
                            if (MapleInventoryManipulator.checkSpace(c, 5750000, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 10, true, false)) {
                                /*  871 */
                                MapleInventoryManipulator.addById(c, 5750000, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /*  873 */
                            c.getPlayer().dropMessage(5, "请检测背包空间是否足够.");

                            break;

                        }
                        /*  876 */
                        c.getPlayer().dropMessage(5, "10个星岩魔方碎片才可以兑换1个星岩魔方.");

                        break;

                    }
                    /*  879 */
                    c.getPlayer().dropMessage(5, "请检测背包空间是否足够.");

                    break;


                case 2430691:
                    /*  883 */
                    if (c.getPlayer().getInventory(MapleInventoryType.CASH).getNumFreeSlot() >= 1) {
                        /*  884 */
                        if (c.getPlayer().getInventory(MapleInventoryType.USE).countById(2430691) >= 10) {
                            /*  885 */
                            if (MapleInventoryManipulator.checkSpace(c, 5750001, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 10, true, false)) {
                                /*  886 */
                                MapleInventoryManipulator.addById(c, 5750001, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /*  888 */
                            c.getPlayer().dropMessage(5, "请检测背包空间是否足够.");

                            break;

                        }
                        /*  891 */
                        c.getPlayer().dropMessage(5, "10个星岩电钻机碎片才可以兑换1个星岩电钻机.");

                        break;

                    }
                    /*  894 */
                    c.getPlayer().dropMessage(5, "请检测背包空间是否足够.");

                    break;


                case 2430692:
                    /*  898 */
                    if (c.getPlayer().getInventory(MapleInventoryType.SETUP).getNumFreeSlot() >= 1) {
                        /*  899 */
                        if (c.getPlayer().getInventory(MapleInventoryType.USE).countById(2430692) >= 1) {
                            /*  900 */
                            int rank = (Randomizer.nextInt(100) < 30) ? ((Randomizer.nextInt(100) < 4) ? 2 : 1) : 0;
                            /*  901 */
                            List<StructItemOption> pots = new LinkedList<>(ii.getAllSocketInfo(rank).values());
                            /*  902 */
                            int newId = 0;
                            /*  903 */
                            while (newId == 0) {
                                /*  904 */
                                StructItemOption pot = pots.get(Randomizer.nextInt(pots.size()));
                                /*  905 */
                                if (pot != null) {
                                    /*  906 */
                                    newId = pot.opID;

                                }

                            }
                            /*  909 */
                            if (MapleInventoryManipulator.checkSpace(c, newId, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 1, true, false)) {
                                /*  910 */
                                int grade = ItemConstants.getNebuliteGrade(newId);
                                /*  911 */
                                if (grade == 2) {
                                    /*  912 */
                                    Item nItem = new Item(newId, (short) 0, (short) 1, (short) 0);
                                    /*  913 */
                                    WorldBroadcastService.getInstance().broadcastMessage(MaplePacketCreator.getGachaponMega(c.getPlayer().getName(), " : 从星岩箱子中获得{" + ii.getName(newId) + "}！大家一起恭喜他（她）吧！！！！", nItem, 1, c.getChannel()));
                                    /*  914 */
                                } else if (grade == 3) {
                                    /*  915 */
                                    Item nItem = new Item(newId, (short) 0, (short) 1, (short) 0);
                                    /*  916 */
                                    WorldBroadcastService.getInstance().broadcastMessage(MaplePacketCreator.getGachaponMega(c.getPlayer().getName(), " : 从星岩箱子中获得{" + ii.getName(newId) + "}！大家一起恭喜他（她）吧！！！！", nItem, 2, c.getChannel()));
                                    /*  917 */
                                } else if (grade == 4) {
                                    /*  918 */
                                    Item nItem = new Item(newId, (short) 0, (short) 1, (short) 0);
                                    /*  919 */
                                    WorldBroadcastService.getInstance().broadcastMessage(MaplePacketCreator.getGachaponMega(c.getPlayer().getName(), " : 从星岩箱子中获得{" + ii.getName(newId) + "}！大家一起恭喜他（她）吧！！！！", nItem, 3, c.getChannel()));

                                }
                                /*  921 */
                                MapleInventoryManipulator.addById(c, newId, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                /*  922 */
                                c.announce(MaplePacketCreator.getShowItemGain(newId, (short) 1, true));
                                /*  923 */
                                chr.getMap().broadcastMessage(InventoryPacket.showNebuliteEffect(chr.getId(), true, "成功交换了星岩。"));
                                /*  924 */
                                c.announce(MaplePacketCreator.craftMessage("你得到了" + ii.getName(newId)));
                                break;

                            }
                            /*  926 */
                            c.getPlayer().dropMessage(5, "请检测背包空间是否足够.");

                            break;

                        }
                        /*  929 */
                        c.getPlayer().dropMessage(5, "您没有星岩箱子.");

                        break;

                    }
                    /*  932 */
                    c.getPlayer().dropMessage(5, "请检测背包空间是否足够.");

                    break;



                case 5680019:
                    /*  937 */
                    hair = 32150 + c.getPlayer().getHair() % 10;
                    /*  938 */
                    c.getPlayer().setHair(hair);
                    /*  939 */
                    c.getPlayer().updateSingleStat(MapleStat.发型, hair);
                    /*  940 */
                    MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.CASH, slot, (short) 1, false);

                    break;




                case 5680020:
                    /*  946 */
                    hair = 32160 + c.getPlayer().getHair() % 10;
                    /*  947 */
                    c.getPlayer().setHair(hair);
                    /*  948 */
                    c.getPlayer().updateSingleStat(MapleStat.发型, hair);
                    /*  949 */
                    MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.CASH, slot, (short) 1, false);

                    break;



                case 3994225:
                    /*  954 */
                    c.getPlayer().dropMessage(5, "Please bring this item to the NPC.");

                    break;

                case 2430212:
                    /*  957 */
                    marr = c.getPlayer().getQuestNAdd(MapleQuest.getInstance(122500));
                    /*  958 */
                    if (marr.getCustomData() == null) {
                        /*  959 */
                        marr.setCustomData("0");

                    }
                    /*  961 */
                    lastTime = Long.parseLong(marr.getCustomData());
                    /*  962 */
                    if (lastTime + 600000L > System.currentTimeMillis()) {
                        /*  963 */
                        c.getPlayer().dropMessage(5, "疲劳恢复药 10分钟内只能使用1次，请稍后在试。");
                        break;
                        /*  964 */
                    }
                    if (c.getPlayer().getFatigue() > 0) {
                        /*  965 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                        /*  966 */
                        c.getPlayer().setFatigue(c.getPlayer().getFatigue() - 5);

                    }

                    break;

                case 2430213:
                    /*  970 */
                    marr = c.getPlayer().getQuestNAdd(MapleQuest.getInstance(122500));
                    /*  971 */
                    if (marr.getCustomData() == null) {
                        /*  972 */
                        marr.setCustomData("0");

                    }
                    /*  974 */
                    lastTime = Long.parseLong(marr.getCustomData());
                    /*  975 */
                    if (lastTime + 600000L > System.currentTimeMillis()) {
                        /*  976 */
                        c.getPlayer().dropMessage(5, "疲劳恢复药 10分钟内只能使用1次，请稍后在试。");
                        break;
                        /*  977 */
                    }
                    if (c.getPlayer().getFatigue() > 0) {
                        /*  978 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                        /*  979 */
                        c.getPlayer().setFatigue(c.getPlayer().getFatigue() - 10);

                    }

                    break;

                case 2430214:

                case 2430220:
                    /*  984 */
                    if (c.getPlayer().getFatigue() > 0) {
                        /*  985 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                        /*  986 */
                        c.getPlayer().setFatigue(c.getPlayer().getFatigue() - 30);

                    }

                    break;

                case 2430227:
                    /*  990 */
                    if (c.getPlayer().getFatigue() > 0) {
                        /*  991 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                        /*  992 */
                        c.getPlayer().setFatigue(c.getPlayer().getFatigue() - 50);

                    }

                    break;

                case 2430231:
                    /*  996 */
                    marr = c.getPlayer().getQuestNAdd(MapleQuest.getInstance(122500));
                    /*  997 */
                    if (marr.getCustomData() == null) {
                        /*  998 */
                        marr.setCustomData("0");

                    }
                    /* 1000 */
                    lastTime = Long.parseLong(marr.getCustomData());
                    /* 1001 */
                    if (lastTime + 600000L > System.currentTimeMillis()) {
                        /* 1002 */
                        c.getPlayer().dropMessage(5, "疲劳恢复药 10分钟内只能使用1次，请稍后在试。");
                        break;
                        /* 1003 */
                    }
                    if (c.getPlayer().getFatigue() > 0) {
                        /* 1004 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                        /* 1005 */
                        c.getPlayer().setFatigue(c.getPlayer().getFatigue() - 40);

                    }

                    break;

                case 2430144:
                    /* 1009 */
                    itemid = Randomizer.nextInt(373) + 2290000;
                    /* 1010 */
                    if (MapleItemInformationProvider.getInstance().itemExists(itemid) && !MapleItemInformationProvider.getInstance().getName(itemid).contains("Special") && !MapleItemInformationProvider.getInstance().getName(itemid).contains("Event")) {
                        /* 1011 */
                        MapleInventoryManipulator.addById(c, itemid, (short) 1, "Reward item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                        /* 1012 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);

                    }

                    break;

                case 2430370:
                    /* 1016 */
                    if (MapleInventoryManipulator.checkSpace(c, 2028062, 1, "")) {
                        /* 1017 */
                        MapleInventoryManipulator.addById(c, 2028062, (short) 1, "Reward item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                        /* 1018 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);

                    }

                    break;

                case 2430158:
                    /* 1022 */
                    if (c.getPlayer().getInventory(MapleInventoryType.ETC).getNumFreeSlot() >= 1) {
                        /* 1023 */
                        if (c.getPlayer().getInventory(MapleInventoryType.ETC).countById(4000630) >= 100) {
                            /* 1024 */
                            if (MapleInventoryManipulator.checkSpace(c, 4310010, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 1, true, false)) {
                                /* 1025 */
                                MapleInventoryManipulator.removeById(c, MapleInventoryType.ETC, 4000630, 100, true, false);
                                /* 1026 */
                                MapleInventoryManipulator.addById(c, 4310010, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /* 1028 */
                            c.getPlayer().dropMessage(5, "其他栏空间位置不足.");
                            break;

                        }
                        /* 1030 */
                        if (c.getPlayer().getInventory(MapleInventoryType.ETC).countById(4000630) >= 50) {
                            /* 1031 */
                            if (MapleInventoryManipulator.checkSpace(c, 4310009, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 1, true, false)) {
                                /* 1032 */
                                MapleInventoryManipulator.removeById(c, MapleInventoryType.ETC, 4000630, 50, true, false);
                                /* 1033 */
                                MapleInventoryManipulator.addById(c, 4310009, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /* 1035 */
                            c.getPlayer().dropMessage(5, "其他栏空间位置不足.");

                            break;

                        }
                        /* 1038 */
                        c.getPlayer().dropMessage(5, "需要50个净化图腾才能兑换出狮子王的贵族勋章，100个净化图腾才能兑换狮子王的皇家勋章。");

                        break;

                    }
                    /* 1041 */
                    c.getPlayer().dropMessage(5, "其他栏空间位置不足.");

                    break;


                case 2430159:
                    /* 1045 */
                    MapleQuest.getInstance(3182).forceComplete(c.getPlayer(), 2161004);
                    /* 1046 */
                    MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);

                    break;

                case 2430200:
                    /* 1049 */
                    if (c.getPlayer().getQuestStatus(31152) != 2) {
                        /* 1050 */
                        c.getPlayer().dropMessage(5, "You have no idea how to use it.");
                        break;
                        /* 1051 */
                    }
                    if (c.getPlayer().getInventory(MapleInventoryType.ETC).getNumFreeSlot() >= 1) {
                        /* 1052 */
                        if (c.getPlayer().getInventory(MapleInventoryType.ETC).countById(4000660) >= 1 && c.getPlayer().getInventory(MapleInventoryType.ETC).countById(4000661) >= 1 && c.getPlayer().getInventory(MapleInventoryType.ETC).countById(4000662) >= 1 && c.getPlayer().getInventory(MapleInventoryType.ETC).countById(4000663) >= 1) {
                            /* 1053 */
                            if (MapleInventoryManipulator.checkSpace(c, 4032923, 1, "") && MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, toUse.getItemId(), 1, true, false) && MapleInventoryManipulator.removeById(c, MapleInventoryType.ETC, 4000660, 1, true, false) && MapleInventoryManipulator.removeById(c, MapleInventoryType.ETC, 4000661, 1, true, false) && MapleInventoryManipulator.removeById(c, MapleInventoryType.ETC, 4000662, 1, true, false) && MapleInventoryManipulator.removeById(c, MapleInventoryType.ETC, 4000663, 1, true, false)) {
                                /* 1054 */
                                MapleInventoryManipulator.addById(c, 4032923, (short) 1, "Scripted item: " + toUse.getItemId() + " on " + DateUtil.getCurrentDate());
                                break;

                            }
                            /* 1056 */
                            c.getPlayer().dropMessage(5, "其他栏空间位置不足.");

                            break;

                        }
                        /* 1059 */
                        c.getPlayer().dropMessage(5, "There needs to be 1 of each Stone for a Dream Key.");

                        break;

                    }
                    /* 1062 */
                    c.getPlayer().dropMessage(5, "其他栏空间位置不足.");

                    break;


                case 2430130:

                case 2430131:
                    /* 1067 */
                    if (JobConstants.is反抗者(c.getPlayer().getJob())) {
                        /* 1068 */
                        MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                        /* 1069 */
                        c.getPlayer().gainExp((20000 + c.getPlayer().getLevel() * 50 * c.getChannelServer().getExpRate()), true, true, false);
                        break;

                    }
                    /* 1071 */
                    c.getPlayer().dropMessage(5, "您无法使用这个道具。");

                    break;


                case 2430132:

                case 2430133:

                case 2430134:

                case 2430142:
                    /* 1078 */
                    if (c.getPlayer().getInventory(MapleInventoryType.EQUIP).getNumFreeSlot() >= 1) {
                        /* 1079 */
                        if (c.getPlayer().getJob() == 3200 || c.getPlayer().getJob() == 3210 || c.getPlayer().getJob() == 3211 || c.getPlayer().getJob() == 3212) {
                            /* 1080 */
                            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                            /* 1081 */
                            MapleInventoryManipulator.addById(c, 1382101, (short) 1, "Scripted item: " + itemId + " on " + DateUtil.getCurrentDate());
                            break;
                            /* 1082 */
                        }
                        if (c.getPlayer().getJob() == 3300 || c.getPlayer().getJob() == 3310 || c.getPlayer().getJob() == 3311 || c.getPlayer().getJob() == 3312) {
                            /* 1083 */
                            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                            /* 1084 */
                            MapleInventoryManipulator.addById(c, 1462093, (short) 1, "Scripted item: " + itemId + " on " + DateUtil.getCurrentDate());
                            break;
                            /* 1085 */
                        }
                        if (c.getPlayer().getJob() == 3500 || c.getPlayer().getJob() == 3510 || c.getPlayer().getJob() == 3511 || c.getPlayer().getJob() == 3512) {
                            /* 1086 */
                            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                            /* 1087 */
                            MapleInventoryManipulator.addById(c, 1492080, (short) 1, "Scripted item: " + itemId + " on " + DateUtil.getCurrentDate());
                            break;

                        }
                        /* 1089 */
                        c.getPlayer().dropMessage(5, "您无法使用这个道具。");

                        break;

                    }
                    /* 1092 */
                    c.getPlayer().dropMessage(5, "背包空间不足。");

                    break;


                case 2430455:
                    /* 1096 */
                    ItemScriptManager.getInstance().start(c, 9010000, toUse);

                    break;

                case 2430036:
                    /* 1099 */
                    mountid = 1027;
                    /* 1100 */
                    expiration_days = 1L;

                    break;

                case 2430170:
                    /* 1103 */
                    mountid = 1027;
                    /* 1104 */
                    expiration_days = 7L;

                    break;

                case 2430037:
                    /* 1107 */
                    mountid = 1028;
                    /* 1108 */
                    expiration_days = 1L;

                    break;

                case 2430038:
                    /* 1111 */
                    mountid = 1029;
                    /* 1112 */
                    expiration_days = 1L;

                    break;

                case 2430039:
                    /* 1115 */
                    mountid = 1030;
                    /* 1116 */
                    expiration_days = 1L;

                    break;

                case 2430040:
                    /* 1119 */
                    mountid = 1031;
                    /* 1120 */
                    expiration_days = 1L;

                    break;

                case 2430223:
                    /* 1123 */
                    mountid = 1031;
                    /* 1124 */
                    expiration_days = 15L;

                    break;

                case 2430259:
                    /* 1127 */
                    mountid = 1031;
                    /* 1128 */
                    expiration_days = 3L;

                    break;

                case 2430242:
                    /* 1131 */
                    mountid = 80001018;
                    /* 1132 */
                    expiration_days = 10L;

                    break;

                case 2430243:
                    /* 1135 */
                    mountid = 80001019;
                    /* 1136 */
                    expiration_days = 10L;

                    break;

                case 2430261:
                    /* 1139 */
                    mountid = 80001019;
                    /* 1140 */
                    expiration_days = 3L;

                    break;

                case 2430249:
                    /* 1143 */
                    mountid = 80001027;
                    /* 1144 */
                    expiration_days = 3L;

                    break;

                case 2430225:
                    /* 1147 */
                    mountid = 1031;
                    /* 1148 */
                    expiration_days = 10L;

                    break;

                case 2430053:
                    /* 1151 */
                    mountid = 1027;
                    /* 1152 */
                    expiration_days = 1L;

                    break;

                case 2430054:
                    /* 1155 */
                    mountid = 1028;
                    /* 1156 */
                    expiration_days = 30L;

                    break;

                case 2430055:
                    /* 1159 */
                    mountid = 1029;
                    /* 1160 */
                    expiration_days = 30L;

                    break;

                case 2430257:
                    /* 1163 */
                    mountid = 1029;
                    /* 1164 */
                    expiration_days = 7L;

                    break;

                case 2430056:
                    /* 1167 */
                    mountid = 1035;
                    /* 1168 */
                    expiration_days = 30L;

                    break;

                case 2430057:
                    /* 1171 */
                    mountid = 1033;
                    /* 1172 */
                    expiration_days = 30L;

                    break;

                case 2430072:
                    /* 1175 */
                    mountid = 1034;
                    /* 1176 */
                    expiration_days = 7L;

                    break;

                case 2430073:
                    /* 1179 */
                    mountid = 1036;
                    /* 1180 */
                    expiration_days = 15L;

                    break;

                case 2430074:
                    /* 1183 */
                    mountid = 1037;
                    /* 1184 */
                    expiration_days = 15L;

                    break;

                case 2430272:
                    /* 1187 */
                    mountid = 1038;
                    /* 1188 */
                    expiration_days = 3L;

                    break;

                case 2430275:
                    /* 1191 */
                    mountid = 80001033;
                    /* 1192 */
                    expiration_days = 7L;

                    break;

                case 2430075:
                    /* 1195 */
                    mountid = 1038;
                    /* 1196 */
                    expiration_days = 15L;

                    break;

                case 2430076:
                    /* 1199 */
                    mountid = 1039;
                    /* 1200 */
                    expiration_days = 15L;

                    break;

                case 2430077:
                    /* 1203 */
                    mountid = 1040;
                    /* 1204 */
                    expiration_days = 15L;

                    break;

                case 2430080:
                    /* 1207 */
                    mountid = 1042;
                    /* 1208 */
                    expiration_days = 20L;

                    break;

                case 2430082:
                    /* 1211 */
                    mountid = 1044;
                    /* 1212 */
                    expiration_days = 7L;

                    break;

                case 2430260:
                    /* 1215 */
                    mountid = 1044;
                    /* 1216 */
                    expiration_days = 3L;

                    break;

                case 2430091:
                    /* 1219 */
                    mountid = 1049;
                    /* 1220 */
                    expiration_days = 10L;

                    break;

                case 2430092:
                    /* 1223 */
                    mountid = 1050;
                    /* 1224 */
                    expiration_days = 10L;

                    break;

                case 2430263:
                    /* 1227 */
                    mountid = 1050;
                    /* 1228 */
                    expiration_days = 3L;

                    break;

                case 2430093:
                    /* 1231 */
                    mountid = 1051;
                    /* 1232 */
                    expiration_days = 10L;

                    break;

                case 2430101:
                    /* 1235 */
                    mountid = 1052;
                    /* 1236 */
                    expiration_days = 10L;

                    break;

                case 2430102:
                    /* 1239 */
                    mountid = 1053;
                    /* 1240 */
                    expiration_days = 10L;

                    break;

                case 2430103:
                    /* 1243 */
                    mountid = 1054;
                    /* 1244 */
                    expiration_days = 30L;

                    break;

                case 2430266:
                    /* 1247 */
                    mountid = 1054;
                    /* 1248 */
                    expiration_days = 3L;

                    break;

                case 2430265:
                    /* 1251 */
                    mountid = 1151;
                    /* 1252 */
                    expiration_days = 3L;

                    break;

                case 2430258:
                    /* 1255 */
                    mountid = 1115;
                    /* 1256 */
                    expiration_days = 365L;

                    break;

                case 2430117:
                    /* 1259 */
                    mountid = 1036;
                    /* 1260 */
                    expiration_days = 365L;

                    break;

                case 2430118:
                    /* 1263 */
                    mountid = 1039;
                    /* 1264 */
                    expiration_days = 365L;

                    break;

                case 2430119:
                    /* 1267 */
                    mountid = 1040;
                    /* 1268 */
                    expiration_days = 365L;

                    break;

                case 2430120:
                    /* 1271 */
                    mountid = 1037;
                    /* 1272 */
                    expiration_days = 365L;

                    break;

                case 2430271:
                    /* 1275 */
                    mountid = 1069;
                    /* 1276 */
                    expiration_days = 3L;

                    break;

                case 2430136:
                    /* 1279 */
                    mountid = 1069;
                    /* 1280 */
                    expiration_days = 15L;

                    break;

                case 2430137:
                    /* 1283 */
                    mountid = 1069;
                    /* 1284 */
                    expiration_days = 30L;

                    break;

                case 2430138:
                    /* 1287 */
                    mountid = 1069;
                    /* 1288 */
                    expiration_days = 365L;

                    break;

                case 2430145:
                    /* 1291 */
                    mountid = 1070;
                    /* 1292 */
                    expiration_days = 30L;

                    break;

                case 2430146:
                    /* 1295 */
                    mountid = 1070;
                    /* 1296 */
                    expiration_days = 365L;

                    break;

                case 2430147:
                    /* 1299 */
                    mountid = 1071;
                    /* 1300 */
                    expiration_days = 30L;

                    break;

                case 2430148:
                    /* 1303 */
                    mountid = 1071;
                    /* 1304 */
                    expiration_days = 365L;

                    break;

                case 2430135:
                    /* 1307 */
                    mountid = 1065;
                    /* 1308 */
                    expiration_days = 15L;

                    break;

                case 2430149:
                    /* 1311 */
                    mountid = 1072;
                    /* 1312 */
                    expiration_days = 30L;

                    break;

                case 2430262:
                    /* 1315 */
                    mountid = 1072;
                    /* 1316 */
                    expiration_days = 3L;

                    break;

                case 2430179:
                    /* 1319 */
                    mountid = 1081;
                    /* 1320 */
                    expiration_days = 15L;

                    break;

                case 2430264:
                    /* 1323 */
                    mountid = 1081;
                    /* 1324 */
                    expiration_days = 3L;

                    break;

                case 2430201:
                    /* 1327 */
                    mountid = 1096;
                    /* 1328 */
                    expiration_days = 3L;

                    break;

                case 2430228:
                    /* 1331 */
                    mountid = 1101;
                    /* 1332 */
                    expiration_days = 15L;

                    break;

                case 2430276:
                    /* 1335 */
                    mountid = 1101;
                    /* 1336 */
                    expiration_days = 15L;

                    break;

                case 2430277:
                    /* 1339 */
                    mountid = 1101;
                    /* 1340 */
                    expiration_days = 365L;

                    break;

                case 2430283:
                    /* 1343 */
                    mountid = 1025;
                    /* 1344 */
                    expiration_days = 10L;

                    break;

                case 2430291:
                    /* 1347 */
                    mountid = 1145;
                    /* 1348 */
                    expiration_days = -1L;

                    break;

                case 2430293:
                    /* 1351 */
                    mountid = 1146;
                    /* 1352 */
                    expiration_days = -1L;

                    break;

                case 2430295:
                    /* 1355 */
                    mountid = 1147;
                    /* 1356 */
                    expiration_days = -1L;

                    break;

                case 2430297:
                    /* 1359 */
                    mountid = 1148;
                    /* 1360 */
                    expiration_days = -1L;

                    break;

                case 2430299:
                    /* 1363 */
                    mountid = 1149;
                    /* 1364 */
                    expiration_days = -1L;

                    break;

                case 2430301:
                    /* 1367 */
                    mountid = 1150;
                    /* 1368 */
                    expiration_days = -1L;

                    break;

                case 2430303:
                    /* 1371 */
                    mountid = 1151;
                    /* 1372 */
                    expiration_days = -1L;

                    break;

                case 2430305:
                    /* 1375 */
                    mountid = 1152;
                    /* 1376 */
                    expiration_days = -1L;

                    break;

                case 2430307:
                    /* 1379 */
                    mountid = 1153;
                    /* 1380 */
                    expiration_days = -1L;

                    break;

                case 2430309:
                    /* 1383 */
                    mountid = 1154;
                    /* 1384 */
                    expiration_days = -1L;

                    break;

                case 2430311:
                    /* 1387 */
                    mountid = 1156;
                    /* 1388 */
                    expiration_days = -1L;

                    break;

                case 2430313:
                    /* 1391 */
                    mountid = 1156;
                    /* 1392 */
                    expiration_days = -1L;

                    break;

                case 2430315:
                    /* 1395 */
                    mountid = 1118;
                    /* 1396 */
                    expiration_days = -1L;

                    break;

                case 2430317:
                    /* 1399 */
                    mountid = 1121;
                    /* 1400 */
                    expiration_days = -1L;

                    break;

                case 2430319:
                    /* 1403 */
                    mountid = 1122;
                    /* 1404 */
                    expiration_days = -1L;

                    break;

                case 2430321:
                    /* 1407 */
                    mountid = 1123;
                    /* 1408 */
                    expiration_days = -1L;

                    break;

                case 2430323:
                    /* 1411 */
                    mountid = 1124;
                    /* 1412 */
                    expiration_days = -1L;

                    break;

                case 2430325:
                    /* 1415 */
                    mountid = 1129;
                    /* 1416 */
                    expiration_days = -1L;

                    break;

                case 2430327:
                    /* 1419 */
                    mountid = 1130;
                    /* 1420 */
                    expiration_days = -1L;

                    break;

                case 2430329:
                    /* 1423 */
                    mountid = 1063;
                    /* 1424 */
                    expiration_days = -1L;

                    break;

                case 2430331:
                    /* 1427 */
                    mountid = 1025;
                    /* 1428 */
                    expiration_days = -1L;

                    break;

                case 2430333:
                    /* 1431 */
                    mountid = 1034;
                    /* 1432 */
                    expiration_days = -1L;

                    break;

                case 2430335:
                    /* 1435 */
                    mountid = 1136;
                    /* 1436 */
                    expiration_days = -1L;

                    break;

                case 2430337:
                    /* 1439 */
                    mountid = 1051;
                    /* 1440 */
                    expiration_days = -1L;

                    break;

                case 2430339:
                    /* 1443 */
                    mountid = 1138;
                    /* 1444 */
                    expiration_days = -1L;

                    break;

                case 2430341:
                    /* 1447 */
                    mountid = 1139;
                    /* 1448 */
                    expiration_days = -1L;

                    break;

                case 2430343:
                    /* 1451 */
                    mountid = 1027;
                    /* 1452 */
                    expiration_days = -1L;

                    break;

                case 2430346:
                    /* 1455 */
                    mountid = 1029;
                    /* 1456 */
                    expiration_days = -1L;

                    break;

                case 2430348:
                    /* 1459 */
                    mountid = 1028;
                    /* 1460 */
                    expiration_days = -1L;

                    break;

                case 2430350:
                    /* 1463 */
                    mountid = 1033;
                    /* 1464 */
                    expiration_days = -1L;

                    break;

                case 2430352:
                    /* 1467 */
                    mountid = 1064;
                    /* 1468 */
                    expiration_days = -1L;

                    break;

                case 2430354:
                    /* 1471 */
                    mountid = 1096;
                    /* 1472 */
                    expiration_days = -1L;

                    break;

                case 2430356:
                    /* 1475 */
                    mountid = 1101;
                    /* 1476 */
                    expiration_days = -1L;

                    break;

                case 2430358:
                    /* 1479 */
                    mountid = 1102;
                    /* 1480 */
                    expiration_days = -1L;

                    break;

                case 2430360:
                    /* 1483 */
                    mountid = 1054;
                    /* 1484 */
                    expiration_days = -1L;

                    break;

                case 2430362:
                    /* 1487 */
                    mountid = 1053;
                    /* 1488 */
                    expiration_days = -1L;

                    break;

                case 2430292:
                    /* 1491 */
                    mountid = 1145;
                    /* 1492 */
                    expiration_days = 90L;

                    break;

                case 2430294:
                    /* 1495 */
                    mountid = 1146;
                    /* 1496 */
                    expiration_days = 90L;

                    break;

                case 2430296:
                    /* 1499 */
                    mountid = 1147;
                    /* 1500 */
                    expiration_days = 90L;

                    break;

                case 2430298:
                    /* 1503 */
                    mountid = 1148;
                    /* 1504 */
                    expiration_days = 90L;

                    break;

                case 2430300:
                    /* 1507 */
                    mountid = 1149;
                    /* 1508 */
                    expiration_days = 90L;

                    break;

                case 2430302:
                    /* 1511 */
                    mountid = 1150;
                    /* 1512 */
                    expiration_days = 90L;

                    break;

                case 2430304:
                    /* 1515 */
                    mountid = 1151;
                    /* 1516 */
                    expiration_days = 90L;

                    break;

                case 2430306:
                    /* 1519 */
                    mountid = 1152;
                    /* 1520 */
                    expiration_days = 90L;

                    break;

                case 2430308:
                    /* 1523 */
                    mountid = 1153;
                    /* 1524 */
                    expiration_days = 90L;

                    break;

                case 2430310:
                    /* 1527 */
                    mountid = 1154;
                    /* 1528 */
                    expiration_days = 90L;

                    break;

                case 2430312:
                    /* 1531 */
                    mountid = 1156;
                    /* 1532 */
                    expiration_days = 90L;

                    break;

                case 2430314:
                    /* 1535 */
                    mountid = 1156;
                    /* 1536 */
                    expiration_days = 90L;

                    break;

                case 2430316:
                    /* 1539 */
                    mountid = 1118;
                    /* 1540 */
                    expiration_days = 90L;

                    break;

                case 2430318:
                    /* 1543 */
                    mountid = 1121;
                    /* 1544 */
                    expiration_days = 90L;

                    break;

                case 2430320:
                    /* 1547 */
                    mountid = 1122;
                    /* 1548 */
                    expiration_days = 90L;

                    break;

                case 2430322:
                    /* 1551 */
                    mountid = 1123;
                    /* 1552 */
                    expiration_days = 90L;

                    break;

                case 2430326:
                    /* 1555 */
                    mountid = 1129;
                    /* 1556 */
                    expiration_days = 90L;

                    break;

                case 2430328:
                    /* 1559 */
                    mountid = 1130;
                    /* 1560 */
                    expiration_days = 90L;

                    break;

                case 2430330:
                    /* 1563 */
                    mountid = 1063;
                    /* 1564 */
                    expiration_days = 90L;

                    break;

                case 2430332:
                    /* 1567 */
                    mountid = 1025;
                    /* 1568 */
                    expiration_days = 90L;

                    break;

                case 2430334:
                    /* 1571 */
                    mountid = 1034;
                    /* 1572 */
                    expiration_days = 90L;

                    break;

                case 2430336:
                    /* 1575 */
                    mountid = 1136;
                    /* 1576 */
                    expiration_days = 90L;

                    break;

                case 2430338:
                    /* 1579 */
                    mountid = 1051;
                    /* 1580 */
                    expiration_days = 90L;

                    break;

                case 2430340:
                    /* 1583 */
                    mountid = 1138;
                    /* 1584 */
                    expiration_days = 90L;

                    break;

                case 2430342:
                    /* 1587 */
                    mountid = 1139;
                    /* 1588 */
                    expiration_days = 90L;

                    break;

                case 2430344:
                    /* 1591 */
                    mountid = 1027;
                    /* 1592 */
                    expiration_days = 90L;

                    break;

                case 2430347:
                    /* 1595 */
                    mountid = 1029;
                    /* 1596 */
                    expiration_days = 90L;

                    break;

                case 2430349:
                    /* 1599 */
                    mountid = 1028;
                    /* 1600 */
                    expiration_days = 90L;

                    break;

                case 2430351:
                    /* 1603 */
                    mountid = 1033;
                    /* 1604 */
                    expiration_days = 90L;

                    break;

                case 2430353:
                    /* 1607 */
                    mountid = 1064;
                    /* 1608 */
                    expiration_days = 90L;

                    break;

                case 2430355:
                    /* 1611 */
                    mountid = 1096;
                    /* 1612 */
                    expiration_days = 90L;

                    break;

                case 2430357:
                    /* 1615 */
                    mountid = 1101;
                    /* 1616 */
                    expiration_days = 90L;

                    break;

                case 2430359:
                    /* 1619 */
                    mountid = 1102;
                    /* 1620 */
                    expiration_days = 90L;

                    break;

                case 2430361:
                    /* 1623 */
                    mountid = 1054;
                    /* 1624 */
                    expiration_days = 90L;

                    break;

                case 2430363:
                    /* 1627 */
                    mountid = 1053;
                    /* 1628 */
                    expiration_days = 90L;

                    break;

                case 2430324:
                    /* 1631 */
                    mountid = 1158;
                    /* 1632 */
                    expiration_days = -1L;

                    break;

                case 2430345:
                    /* 1635 */
                    mountid = 1158;
                    /* 1636 */
                    expiration_days = 90L;

                    break;

                case 2430367:
                    /* 1639 */
                    mountid = 1115;
                    /* 1640 */
                    expiration_days = 3L;

                    break;

                case 2430365:
                    /* 1643 */
                    mountid = 1025;
                    /* 1644 */
                    expiration_days = 365L;

                    break;

                case 2430366:
                    /* 1647 */
                    mountid = 1025;
                    /* 1648 */
                    expiration_days = 15L;

                    break;

                case 2430369:
                    /* 1651 */
                    mountid = 1049;
                    /* 1652 */
                    expiration_days = 10L;

                    break;

                case 2430392:
                    /* 1655 */
                    mountid = 80001038;
                    /* 1656 */
                    expiration_days = 90L;

                    break;

                case 2430476:
                    /* 1659 */
                    mountid = 1039;
                    /* 1660 */
                    expiration_days = 15L;

                    break;

                case 2430477:
                    /* 1663 */
                    mountid = 1039;
                    /* 1664 */
                    expiration_days = 365L;

                    break;

                case 2430232:
                    /* 1667 */
                    mountid = 1106;
                    /* 1668 */
                    expiration_days = 10L;

                    break;

                case 2430511:
                    /* 1671 */
                    mountid = 80001033;
                    /* 1672 */
                    expiration_days = 15L;

                    break;

                case 2430512:
                    /* 1675 */
                    mountid = 80001033;
                    /* 1676 */
                    expiration_days = 365L;

                    break;

                case 2430536:
                    /* 1679 */
                    mountid = 80001114;
                    /* 1680 */
                    expiration_days = -1L;

                    break;

                case 2430537:
                    /* 1683 */
                    mountid = 80001114;
                    /* 1684 */
                    expiration_days = 90L;

                    break;

                case 2430229:
                    /* 1687 */
                    mountid = 1102;
                    /* 1688 */
                    expiration_days = 60L;

                    break;

                case 2430199:
                    /* 1691 */
                    mountid = 1089;
                    /* 1692 */
                    expiration_days = 1L;

                    break;

                case 2432311:
                    /* 1695 */
                    mountid = 1089;
                    /* 1696 */
                    expiration_days = -1L;

                    break;

                case 2430211:
                    /* 1699 */
                    mountid = 80001009;
                    /* 1700 */
                    expiration_days = 30L;

                    break;

                case 2430521:
                    /* 1703 */
                    mountid = 80001326;
                    /* 1704 */
                    expiration_days = 30L;

                    break;

                case 2432497:
                    /* 1707 */
                    mountid = 80011029;
                    /* 1708 */
                    expiration_days = -1L;

                    break;

                case 2430707:
                    /* 1711 */
                    mountid = 80001348;
                    /* 1712 */
                    expiration_days = -1L;

                    break;

                case 2430464:
                    /* 1715 */
                    mountid = 80001120;
                    /* 1716 */
                    expiration_days = -1L;

                    break;

                case 2432735:
                    /* 1719 */
                    mountid = 80001112;
                    /* 1720 */
                    expiration_days = -1L;

                    break;

                case 2432733:
                    /* 1723 */
                    mountid = 80001552;
                    /* 1724 */
                    expiration_days = -1L;

                    break;

                case 2432487:
                    /* 1727 */
                    mountid = 80001531;
                    /* 1728 */
                    expiration_days = -1L;

                    break;

                case 2432496:
                    /* 1731 */
                    mountid = 80011028;
                    /* 1732 */
                    expiration_days = -1L;

                    break;

                case 2432518:
                    /* 1735 */
                    mountid = 80011030;
                    /* 1736 */
                    expiration_days = -1L;

                    break;

                case 2430534:
                    /* 1739 */
                    mountid = 80001113;
                    /* 1740 */
                    expiration_days = -1L;

                    break;

                case 2430992:
                    /* 1743 */
                    mountid = 80001181;
                    /* 1744 */
                    expiration_days = 7L;

                    break;

                case 2430993:
                    /* 1747 */
                    mountid = 80001181;
                    /* 1748 */
                    expiration_days = 30L;

                    break;

                case 2430994:
                    /* 1751 */
                    mountid = 80001181;
                    /* 1752 */
                    expiration_days = 90L;

                    break;

                case 2430938:
                    /* 1755 */
                    mountid = 80001194;
                    /* 1756 */
                    expiration_days = -1L;

                    break;

                case 2430939:
                    /* 1759 */
                    mountid = 80001195;
                    /* 1760 */
                    expiration_days = -1L;

                    break;

                case 2430968:
                    /* 1763 */
                    mountid = 80001196;
                    /* 1764 */
                    expiration_days = -1L;

                    break;

                case 2431137:
                    /* 1767 */
                    mountid = 80001198;
                    /* 1768 */
                    expiration_days = -1L;

                    break;

                case 2431073:
                    /* 1771 */
                    mountid = 80001199;
                    /* 1772 */
                    expiration_days = -1L;

                    break;

                case 2431135:
                    /* 1775 */
                    mountid = 80001220;
                    /* 1776 */
                    expiration_days = -1L;

                    break;

                case 2431136:
                    /* 1779 */
                    mountid = 80001221;
                    /* 1780 */
                    expiration_days = -1L;

                    break;

                case 2431268:
                    /* 1783 */
                    mountid = 80001228;
                    /* 1784 */
                    expiration_days = -1L;

                    break;

                case 2431353:
                    /* 1787 */
                    mountid = 80001237;
                    /* 1788 */
                    expiration_days = -1L;

                    break;

                case 2431362:
                    /* 1791 */
                    mountid = 80001240;
                    /* 1792 */
                    expiration_days = -1L;

                    break;





                case 2431423:
                    /* 1799 */
                    mountid = 80001243;
                    /* 1800 */
                    expiration_days = -1L;

                    break;

                case 2431424:
                    /* 1803 */
                    mountid = 80011175;
                    /* 1804 */
                    expiration_days = -1L;

                    break;

                case 2431425:
                    /* 1807 */
                    mountid = 80001245;
                    /* 1808 */
                    expiration_days = -1L;

                    break;

                case 2431426:
                    /* 1811 */
                    mountid = 80001645;
                    /* 1812 */
                    expiration_days = -1L;

                    break;

                case 2431473:
                    /* 1815 */
                    mountid = 80001257;
                    /* 1816 */
                    expiration_days = -1L;

                    break;

                case 2431474:
                    /* 1819 */
                    mountid = 80001258;
                    /* 1820 */
                    expiration_days = -1L;

                    break;

                case 2434377:
                    /* 1823 */
                    mountid = 80001792;
                    /* 1824 */
                    expiration_days = -1L;

                    break;

                case 2434379:
                    /* 1827 */
                    mountid = 80001790;
                    /* 1828 */
                    expiration_days = -1L;

                    break;

                case 2434277:
                    /* 1831 */
                    mountid = 80001786;
                    /* 1832 */
                    expiration_days = -1L;

                    break;

                case 2432172:
                    /* 1835 */
                    mountid = 80001410;
                    /* 1836 */
                    expiration_days = -1L;

                    break;

                case 2432992:
                    /* 1839 */
                    mountid = 80011109;
                    /* 1840 */
                    expiration_days = -1L;

                    break;

                case 2433069:
                    /* 1843 */
                    mountid = 80011110;
                    /* 1844 */
                    expiration_days = -1L;

                    break;

                case 2432806:
                    /* 1847 */
                    mountid = 80001557;
                    /* 1848 */
                    expiration_days = -1L;

                    break;

                case 2432994:
                    /* 1851 */
                    mountid = 80001561;
                    /* 1852 */
                    expiration_days = -1L;

                    break;

                case 2432995:
                    /* 1855 */
                    mountid = 80001562;
                    /* 1856 */
                    expiration_days = -1L;

                    break;

                case 2432996:
                    /* 1859 */
                    mountid = 80001563;
                    /* 1860 */
                    expiration_days = -1L;

                    break;

                case 2432997:
                    /* 1863 */
                    mountid = 80001564;
                    /* 1864 */
                    expiration_days = -1L;

                    break;

                case 2432998:
                    /* 1867 */
                    mountid = 80001565;
                    /* 1868 */
                    expiration_days = -1L;

                    break;

                case 2432999:
                    /* 1871 */
                    mountid = 80001566;
                    /* 1872 */
                    expiration_days = -1L;

                    break;

                case 2433000:
                    /* 1875 */
                    mountid = 80001567;
                    /* 1876 */
                    expiration_days = -1L;

                    break;

                case 2433001:
                    /* 1879 */
                    mountid = 80001568;
                    /* 1880 */
                    expiration_days = -1L;

                    break;

                case 2433002:
                    /* 1883 */
                    mountid = 80001569;
                    /* 1884 */
                    expiration_days = -1L;

                    break;

                case 2433003:
                    /* 1887 */
                    mountid = 80001570;
                    /* 1888 */
                    expiration_days = -1L;

                    break;

                case 2433051:
                    /* 1891 */
                    mountid = 80001582;
                    /* 1892 */
                    expiration_days = -1L;

                    break;

                case 2433053:
                    /* 1895 */
                    mountid = 80001584;
                    /* 1896 */
                    expiration_days = -1L;

                    break;

                case 2431898:
                    /* 1899 */
                    mountid = 80001324;
                    /* 1900 */
                    expiration_days = -1L;

                    break;

                case 2431914:
                    /* 1903 */
                    mountid = 80001326;
                    /* 1904 */
                    expiration_days = 30L;

                    break;

                case 2431915:
                    /* 1907 */
                    mountid = 80001327;
                    /* 1908 */
                    expiration_days = -1L;

                    break;

                case 2432003:
                    /* 1911 */
                    mountid = 80001331;
                    /* 1912 */
                    expiration_days = 10L;

                    break;

                case 2432007:
                    /* 1915 */
                    mountid = 80001345;
                    /* 1916 */
                    expiration_days = 10L;

                    break;

                case 2432029:
                    /* 1919 */
                    mountid = 80001346;
                    /* 1920 */
                    expiration_days = 90L;

                    break;

                case 2432030:
                    /* 1923 */
                    mountid = 80001347;
                    /* 1924 */
                    expiration_days = -1L;

                    break;

                case 2432031:
                    /* 1927 */
                    mountid = 80001348;
                    /* 1928 */
                    expiration_days = -1L;

                    break;

                case 2432078:
                    /* 1931 */
                    mountid = 80001353;
                    /* 1932 */
                    expiration_days = -1L;

                    break;

                case 2432085:
                    /* 1935 */
                    mountid = 80001355;
                    /* 1936 */
                    expiration_days = -1L;

                    break;

                case 2431883:
                    /* 1939 */
                    mountid = 80001330;
                    /* 1940 */
                    expiration_days = -1L;

                    break;

                case 2431765:
                    /* 1943 */
                    mountid = 80001290;
                    /* 1944 */
                    expiration_days = -1L;

                    break;

                case 2432015:
                    /* 1947 */
                    mountid = 80001333;
                    /* 1948 */
                    expiration_days = -1L;

                    break;

                case 2432099:
                    /* 1951 */
                    mountid = 80001336;
                    /* 1952 */
                    expiration_days = 30L;

                    break;

                case 2431950:
                    /* 1955 */
                    mountid = 80001337;
                    /* 1956 */
                    expiration_days = 90L;

                    break;

                case 2432149:
                    /* 1959 */
                    mountid = 80001398;
                    /* 1960 */
                    expiration_days = -1L;

                    break;

                case 2432151:
                    /* 1963 */
                    mountid = 80001400;
                    /* 1964 */
                    expiration_days = -1L;

                    break;

                case 2432309:
                    /* 1967 */
                    mountid = 80001404;
                    /* 1968 */
                    expiration_days = -1L;

                    break;

                case 2432328:
                    /* 1971 */
                    mountid = 80001435;
                    /* 1972 */
                    expiration_days = 30L;

                    break;

                case 2432216:
                    /* 1975 */
                    mountid = 80001411;
                    /* 1976 */
                    expiration_days = -1L;

                    break;

                case 2432218:
                    /* 1979 */
                    mountid = 80001413;
                    /* 1980 */
                    expiration_days = -1L;

                    break;

                case 2432291:
                    /* 1983 */
                    mountid = 80001419;
                    /* 1984 */
                    expiration_days = -1L;

                    break;

                case 2432293:
                    /* 1987 */
                    mountid = 80001421;
                    /* 1988 */
                    expiration_days = -1L;

                    break;

                case 2432295:
                    /* 1991 */
                    mountid = 80001423;
                    /* 1992 */
                    expiration_days = -1L;

                    break;

                case 2432347:
                    /* 1995 */
                    mountid = 80001440;
                    /* 1996 */
                    expiration_days = -1L;

                    break;

                case 2432348:
                    /* 1999 */
                    mountid = 80001441;
                    /* 2000 */
                    expiration_days = -1L;

                    break;

                case 2432349:
                    /* 2003 */
                    mountid = 80001442;
                    /* 2004 */
                    expiration_days = -1L;

                    break;

                case 2432350:
                    /* 2007 */
                    mountid = 80001443;
                    /* 2008 */
                    expiration_days = -1L;

                    break;

                case 2432351:
                    /* 2011 */
                    mountid = 80001444;
                    /* 2012 */
                    expiration_days = -1L;

                    break;

                case 2432431:
                    /* 2015 */
                    mountid = 80001480;
                    /* 2016 */
                    expiration_days = -1L;

                    break;

                case 2432433:
                    /* 2019 */
                    mountid = 80001482;
                    /* 2020 */
                    expiration_days = -1L;

                    break;

                case 2432449:
                    /* 2023 */
                    mountid = 80001484;
                    /* 2024 */
                    expiration_days = -1L;

                    break;

                case 2432582:
                    /* 2027 */
                    mountid = 80001505;
                    /* 2028 */
                    expiration_days = -1L;

                    break;

                case 2432498:
                    /* 2031 */
                    mountid = 80001508;
                    /* 2032 */
                    expiration_days = -1L;

                    break;

                case 2432500:
                    /* 2035 */
                    mountid = 80001510;
                    /* 2036 */
                    expiration_days = -1L;

                    break;

                case 2432645:
                    /* 2039 */
                    mountid = 80001531;
                    /* 2040 */
                    expiration_days = -1L;

                    break;

                case 2432653:
                    /* 2043 */
                    mountid = 80001533;
                    /* 2044 */
                    expiration_days = -1L;

                    break;

                case 2432654:
                    /* 2047 */
                    mountid = 80001534;
                    /* 2048 */
                    expiration_days = 90L;

                    break;

                case 2434127:
                    /* 2051 */
                    mountid = 80001549;
                    /* 2052 */
                    expiration_days = -1L;

                    break;

                case 2433499:
                    /* 2055 */
                    mountid = 80001671;
                    /* 2056 */
                    expiration_days = -1L;

                    break;

                case 2433501:
                    /* 2059 */
                    mountid = 80001673;
                    /* 2060 */
                    expiration_days = -1L;

                    break;

                case 2433735:
                    /* 2063 */
                    mountid = 80001707;
                    /* 2064 */
                    expiration_days = -1L;

                    break;

                case 2433736:
                    /* 2067 */
                    mountid = 80001708;
                    /* 2068 */
                    expiration_days = -1L;

                    break;

                case 2433809:
                    /* 2071 */
                    mountid = 80001711;
                    /* 2072 */
                    expiration_days = -1L;

                    break;

                case 2433811:
                    /* 2075 */
                    mountid = 80001713;
                    /* 2076 */
                    expiration_days = -1L;

                    break;

                case 2433292:
                    /* 2079 */
                    mountid = 80011139;
                    /* 2080 */
                    expiration_days = -1L;

                    break;

                case 2433293:
                    /* 2083 */
                    mountid = 80011140;
                    /* 2084 */
                    expiration_days = -1L;

                    break;

                case 2433497:
                    /* 2087 */
                    mountid = 80011147;
                    /* 2088 */
                    expiration_days = -1L;

                    break;

                case 2433511:
                    /* 2091 */
                    mountid = 80011148;
                    /* 2092 */
                    expiration_days = -1L;

                    break;

                case 2434084:
                    /* 2095 */
                    mountid = 80001701;
                    /* 2096 */
                    expiration_days = -1L;

                    break;

                case 2434142:
                    /* 2099 */
                    mountid = 80011205;
                    /* 2100 */
                    expiration_days = -1L;

                    break;

                case 2434143:
                    /* 2103 */
                    mountid = 80011206;
                    /* 2104 */
                    expiration_days = -1L;

                    break;

                case 2434235:
                    /* 2107 */
                    mountid = 80011236;
                    /* 2108 */
                    expiration_days = -1L;

                    break;

                case 2434236:
                    /* 2111 */
                    mountid = 80011237;
                    /* 2112 */
                    expiration_days = -1L;

                    break;

                case 2434037:
                    /* 2115 */
                    mountid = 80011157;
                    /* 2116 */
                    expiration_days = -1L;

                    break;

                case 2433836:
                    /* 2119 */
                    mountid = 80011179;
                    /* 2120 */
                    expiration_days = -1L;

                    break;

                case 2433058:
                    /* 2123 */
                    mountid = 80011180;
                    /* 2124 */
                    expiration_days = -1L;

                    break;

                case 2433059:
                    /* 2127 */
                    mountid = 80011181;
                    /* 2128 */
                    expiration_days = -1L;

                    break;

                case 2433060:
                    /* 2131 */
                    mountid = 80011182;
                    /* 2132 */
                    expiration_days = -1L;

                    break;

                case 2433168:
                    /* 2135 */
                    mountid = 80011183;
                    /* 2136 */
                    expiration_days = -1L;

                    break;

                case 2433169:
                    /* 2139 */
                    mountid = 80011184;
                    /* 2140 */
                    expiration_days = -1L;

                    break;

                case 2433170:
                    /* 2143 */
                    mountid = 80011185;
                    /* 2144 */
                    expiration_days = -1L;

                    break;

                case 2433198:
                    /* 2147 */
                    mountid = 80011186;
                    /* 2148 */
                    expiration_days = -1L;

                    break;

                case 2433881:
                    /* 2151 */
                    mountid = 80011190;
                    /* 2152 */
                    expiration_days = -1L;

                    break;

                case 2433876:
                    /* 2155 */
                    mountid = 80011189;
                    /* 2156 */
                    expiration_days = -1L;

                    break;

                case 2434082:
                    /* 2159 */
                    mountid = 80011199;
                    /* 2160 */
                    expiration_days = -1L;

                    break;

                case 2434083:
                    /* 2163 */
                    mountid = 80011200;
                    /* 2164 */
                    expiration_days = -1L;

                    break;

                case 2435116:
                    /* 2167 */
                    mountid = 80011303;

                    break;


                case 2435133:
                    /* 2171 */
                    mountid = 80011289;
                    /* 2172 */
                    expiration_days = 30L;

                    break;


                case 2435036:
                    /* 2176 */
                    mountid = 80011289;
                    /* 2177 */
                    expiration_days = -1L;

                    break;


                case 2434965:
                    /* 2181 */
                    mountid = 80011279;
                    /* 2182 */
                    expiration_days = 30L;

                    break;


                case 2434867:
                    /* 2186 */
                    mountid = 80011279;
                    /* 2187 */
                    expiration_days = 90L;

                    break;


                case 2434360:
                    /* 2191 */
                    mountid = 80011279;
                    /* 2192 */
                    expiration_days = -1L;

                    break;


                case 2434690:
                    /* 2196 */
                    mountid = 80011272;
                    /* 2197 */
                    expiration_days = -1L;

                    break;


                case 2434618:
                    /* 2201 */
                    mountid = 80011263;
                    /* 2202 */
                    expiration_days = -1L;

                    break;


                case 2434603:
                    /* 2206 */
                    mountid = 80011262;
                    /* 2207 */
                    expiration_days = -1L;

                    break;


                case 2433742:
                    /* 2211 */
                    mountid = 80011148;
                    /* 2212 */
                    expiration_days = 30L;

                    break;


                case 2433743:
                    /* 2216 */
                    mountid = 80011147;
                    /* 2217 */
                    expiration_days = 30L;

                    break;


                case 2434163:
                    /* 2221 */
                    mountid = 80011027;
                    /* 2222 */
                    expiration_days = -1L;

                    break;


                case 2432483:
                    /* 2226 */
                    mountid = 80011027;
                    /* 2227 */
                    expiration_days = 90L;

                    break;


                case 2434737:
                    /* 2231 */
                    mountid = 80001923;
                    /* 2232 */
                    expiration_days = -1L;

                    break;


                case 2434649:
                    /* 2236 */
                    mountid = 80001918;
                    /* 2237 */
                    expiration_days = -1L;

                    break;


                case 2435103:
                    /* 2241 */
                    mountid = 80001814;
                    /* 2242 */
                    expiration_days = 90L;

                    break;


                case 2434518:
                    /* 2246 */
                    mountid = 80001814;
                    /* 2247 */
                    expiration_days = 90L;

                    break;


                case 2434517:
                    /* 2251 */
                    mountid = 80001814;
                    /* 2252 */
                    expiration_days = -1L;

                    break;


                case 2434516:
                    /* 2256 */
                    mountid = 80001811;
                    /* 2257 */
                    expiration_days = 90L;

                    break;


                case 2434515:
                    /* 2261 */
                    mountid = 80001811;
                    /* 2262 */
                    expiration_days = -1L;

                    break;


                case 2434378:
                    /* 2266 */
                    mountid = 80001792;
                    /* 2267 */
                    expiration_days = 90L;

                    break;


                case 2434380:
                    /* 2271 */
                    mountid = 80001790;
                    /* 2272 */
                    expiration_days = 90L;

                    break;


                case 2434278:
                    /* 2276 */
                    mountid = 80001787;
                    /* 2277 */
                    expiration_days = 90L;

                    break;


                case 2434276:
                    /* 2281 */
                    mountid = 80001785;
                    /* 2282 */
                    expiration_days = 90L;

                    break;


                case 2434275:
                    /* 2286 */
                    mountid = 80001784;
                    /* 2287 */
                    expiration_days = -1L;

                    break;


                case 2434079:
                    /* 2291 */
                    mountid = 80001779;
                    /* 2292 */
                    expiration_days = -1L;

                    break;


                case 2434080:
                    /* 2296 */
                    mountid = 80001778;
                    /* 2297 */
                    expiration_days = 90L;

                    break;


                case 2434078:
                    /* 2301 */
                    mountid = 80001777;
                    /* 2302 */
                    expiration_days = 90L;

                    break;


                case 2434077:
                    /* 2306 */
                    mountid = 80001776;
                    /* 2307 */
                    expiration_days = -1L;

                    break;


                case 2434013:
                    /* 2311 */
                    mountid = 80001775;
                    /* 2312 */
                    expiration_days = 30L;

                    break;


                case 2434025:
                    /* 2316 */
                    mountid = 80001774;
                    /* 2317 */
                    expiration_days = 30L;

                    break;


                case 2433949:
                    /* 2321 */
                    mountid = 80001767;
                    /* 2322 */
                    expiration_days = 90L;

                    break;


                case 2433948:
                    /* 2326 */
                    mountid = 80001766;
                    /* 2327 */
                    expiration_days = -1L;

                    break;


                case 2433947:
                    /* 2331 */
                    mountid = 80001765;
                    /* 2332 */
                    expiration_days = 90L;

                    break;


                case 2433946:
                    /* 2336 */
                    mountid = 80001764;
                    /* 2337 */
                    expiration_days = -1L;

                    break;


                case 2433932:
                    /* 2341 */
                    mountid = 80001763;
                    /* 2342 */
                    expiration_days = 30L;

                    break;


                case 2433812:
                    /* 2346 */
                    mountid = 80001714;
                    /* 2347 */
                    expiration_days = 90L;

                    break;


                case 2433810:
                    /* 2351 */
                    mountid = 80001712;
                    /* 2352 */
                    expiration_days = 90L;

                    break;


                case 2433734:
                    /* 2356 */
                    mountid = 80001708;
                    /* 2357 */
                    expiration_days = 90L;

                    break;


                case 2433500:
                    /* 2361 */
                    mountid = 80001673;
                    /* 2362 */
                    expiration_days = 90L;

                    break;


                case 2433498:
                    /* 2366 */
                    mountid = 80001671;
                    /* 2367 */
                    expiration_days = 90L;

                    break;


                case 2431542:
                    /* 2371 */
                    mountid = 80001645;
                    /* 2372 */
                    expiration_days = 90L;

                    break;


                case 2431530:
                    /* 2376 */
                    mountid = 80001645;
                    /* 2377 */
                    expiration_days = 30L;

                    break;


                case 2433350:
                    /* 2381 */
                    mountid = 80001628;
                    /* 2382 */
                    expiration_days = 90L;

                    break;


                case 2433349:
                    /* 2386 */
                    mountid = 80001627;
                    /* 2387 */
                    expiration_days = -1L;

                    break;


                case 2433348:
                    /* 2391 */
                    mountid = 80001626;
                    /* 2392 */
                    expiration_days = 90L;

                    break;


                case 2433347:
                    /* 2396 */
                    mountid = 80001625;
                    /* 2397 */
                    expiration_days = -1L;

                    break;


                case 2433346:
                    /* 2401 */
                    mountid = 80001624;
                    /* 2402 */
                    expiration_days = 90L;

                    break;


                case 2433345:
                    /* 2406 */
                    mountid = 80001623;
                    /* 2407 */
                    expiration_days = -1L;

                    break;


                case 2433277:
                    /* 2411 */
                    mountid = 80001622;
                    /* 2412 */
                    expiration_days = 90L;

                    break;


                case 2433276:
                    /* 2416 */
                    mountid = 80001621;
                    /* 2417 */
                    expiration_days = -1L;

                    break;


                case 2433275:
                    /* 2421 */
                    mountid = 80001620;
                    /* 2422 */
                    expiration_days = 90L;

                    break;


                case 2433274:
                    /* 2426 */
                    mountid = 80001619;
                    /* 2427 */
                    expiration_days = -1L;

                    break;


                case 2433273:
                    /* 2431 */
                    mountid = 80001618;
                    /* 2432 */
                    expiration_days = 90L;

                    break;


                case 2433272:
                    /* 2436 */
                    mountid = 80001617;
                    /* 2437 */
                    expiration_days = -1L;

                    break;


                case 2433054:
                    /* 2441 */
                    mountid = 80001585;
                    /* 2442 */
                    expiration_days = 90L;

                    break;


                case 2433052:
                    /* 2446 */
                    mountid = 80001583;
                    /* 2447 */
                    expiration_days = 90L;

                    break;


                case 2432807:
                    /* 2451 */
                    mountid = 80001558;
                    /* 2452 */
                    expiration_days = 90L;

                    break;


                case 2432752:
                    /* 2456 */
                    mountid = 80001555;
                    /* 2457 */
                    expiration_days = 90L;

                    break;


                case 2432751:
                    /* 2461 */
                    mountid = 80001554;
                    /* 2462 */
                    expiration_days = -1L;

                    break;


                case 2432734:
                    /* 2466 */
                    mountid = 80001553;
                    /* 2467 */
                    expiration_days = 90L;

                    break;


                case 2432501:
                    /* 2471 */
                    mountid = 80001511;
                    /* 2472 */
                    expiration_days = 90L;

                    break;


                case 2432499:
                    /* 2476 */
                    mountid = 80001509;
                    /* 2477 */
                    expiration_days = 90L;

                    break;


                case 2432583:
                    /* 2481 */
                    mountid = 80001506;
                    /* 2482 */
                    expiration_days = 90L;

                    break;


                case 2432581:
                    /* 2486 */
                    mountid = 80001504;
                    /* 2487 */
                    expiration_days = 90L;

                    break;


                case 2432580:
                    /* 2491 */
                    mountid = 80001503;
                    /* 2492 */
                    expiration_days = -1L;

                    break;


                case 2432552:
                    /* 2496 */
                    mountid = 80001492;
                    /* 2497 */
                    expiration_days = -1L;

                    break;


                case 2432528:
                    /* 2501 */
                    mountid = 80001491;
                    /* 2502 */
                    expiration_days = 90L;

                    break;


                case 2432527:
                    /* 2506 */
                    mountid = 80001490;
                    /* 2507 */
                    expiration_days = 90L;

                    break;


                case 2432450:
                    /* 2511 */
                    mountid = 80001485;
                    /* 2512 */
                    expiration_days = 90L;

                    break;


                case 2432434:
                    /* 2516 */
                    mountid = 80001483;
                    /* 2517 */
                    expiration_days = 90L;

                    break;


                case 2432432:
                    /* 2521 */
                    mountid = 80001481;
                    /* 2522 */
                    expiration_days = 90L;

                    break;


                case 2432362:
                    /* 2526 */
                    mountid = 80001448;
                    /* 2527 */
                    expiration_days = 90L;

                    break;


                case 2432361:
                    /* 2531 */
                    mountid = 80001447;
                    /* 2532 */
                    expiration_days = 30L;

                    break;


                case 2432296:
                    /* 2536 */
                    mountid = 80001424;
                    /* 2537 */
                    expiration_days = 90L;

                    break;


                case 2432294:
                    /* 2541 */
                    mountid = 80001422;
                    /* 2542 */
                    expiration_days = 90L;

                    break;


                case 2432292:
                    /* 2546 */
                    mountid = 80001420;
                    /* 2547 */
                    expiration_days = 90L;

                    break;


                case 2432219:
                    /* 2551 */
                    mountid = 80001414;
                    /* 2552 */
                    expiration_days = 90L;

                    break;


                case 2432217:
                    /* 2556 */
                    mountid = 80001412;
                    /* 2557 */
                    expiration_days = 90L;

                    break;


                case 2434567:
                    /* 2561 */
                    mountid = 80001410;
                    /* 2562 */
                    expiration_days = 90L;

                    break;


                case 2432167:
                    /* 2566 */
                    mountid = 80001403;
                    /* 2567 */
                    expiration_days = -1L;

                    break;


                case 2432152:
                    /* 2571 */
                    mountid = 80001401;
                    /* 2572 */
                    expiration_days = 90L;

                    break;


                case 2432135:
                    /* 2576 */
                    mountid = 80001397;
                    /* 2577 */
                    expiration_days = 30L;

                    break;


                case 2432079:
                    /* 2581 */
                    mountid = 80001354;
                    /* 2582 */
                    expiration_days = 90L;

                    break;


                case 2432006:
                    /* 2586 */
                    mountid = 80001345;
                    /* 2587 */
                    expiration_days = 1L;

                    break;


                case 2431949:
                    /* 2591 */
                    mountid = 80001336;
                    /* 2592 */
                    expiration_days = -1L;

                    break;


                case 2431916:
                    /* 2596 */
                    mountid = 80001328;
                    /* 2597 */
                    expiration_days = 90L;

                    break;


                case 2431899:
                    /* 2601 */
                    mountid = 80001325;
                    /* 2602 */
                    expiration_days = 90L;

                    break;


                case 2430079:
                    /* 2606 */
                    mountid = 80001293;
                    /* 2607 */
                    expiration_days = 172800000L;

                    break;


                case 2431758:
                    /* 2611 */
                    mountid = 80001288;
                    /* 2612 */
                    expiration_days = 1440000L;

                    break;


                case 2431757:
                    /* 2616 */
                    mountid = 80001287;
                    /* 2617 */
                    expiration_days = 7L;

                    break;


                case 2431756:
                    /* 2621 */
                    mountid = 80001285;
                    /* 2622 */
                    expiration_days = 3L;

                    break;


                case 2431755:
                    /* 2626 */
                    mountid = 80001285;
                    /* 2627 */
                    expiration_days = 1L;

                    break;


                case 2431745:
                    /* 2631 */
                    mountid = 80001278;
                    /* 2632 */
                    expiration_days = -1L;

                    break;


                case 2431733:
                    /* 2636 */
                    mountid = 80001278;
                    /* 2637 */
                    expiration_days = -1L;

                    break;


                case 2431722:
                    /* 2641 */
                    mountid = 80001261;
                    /* 2642 */
                    expiration_days = 90L;

                    break;


                case 2431700:
                    /* 2646 */
                    mountid = 80001261;
                    /* 2647 */
                    expiration_days = 30L;

                    break;


                case 2431573:
                    /* 2651 */
                    mountid = 80001261;
                    /* 2652 */
                    expiration_days = -1L;

                    break;


                case 2431464:
                    /* 2656 */
                    mountid = 80001246;
                    /* 2657 */
                    expiration_days = -1L;

                    break;


                case 2431529:
                    /* 2661 */
                    mountid = 80001245;
                    /* 2662 */
                    expiration_days = 30L;

                    break;


                case 2431462:
                    /* 2666 */
                    mountid = 80001245;
                    /* 2667 */
                    expiration_days = -1L;

                    break;


                case 2431541:
                    /* 2671 */
                    mountid = 80001243;
                    /* 2672 */
                    expiration_days = 90L;

                    break;


                case 2434477:
                    /* 2676 */
                    mountid = 80001196;
                    /* 2677 */
                    expiration_days = -1L;

                    break;


                case 2431697:
                    /* 2681 */
                    mountid = 80001166;
                    /* 2682 */
                    expiration_days = -1L;

                    break;


                case 2431833:
                    /* 2686 */
                    mountid = 80001114;
                    /* 2687 */
                    expiration_days = 50L;

                    break;


                case 2430203:
                    /* 2691 */
                    mountid = 80001084;
                    /* 2692 */
                    expiration_days = 30L;

                    break;


                case 2430081:
                    /* 2696 */
                    mountid = 80001024;
                    /* 2697 */
                    expiration_days = 7L;

                    break;


                case 2431698:
                    /* 2701 */
                    mountid = 80001013;
                    /* 2702 */
                    expiration_days = -1L;

                    break;


                case 2430050:
                    /* 2706 */
                    mountid = 80001504;
                    /* 2707 */
                    expiration_days = 5L;

                    break;


                case 2434191:
                    /* 2711 */
                    mountid = 80001148;
                    /* 2712 */
                    expiration_days = -1L;

                    break;


                case 2434161:
                    /* 2716 */
                    mountid = 80001240;
                    /* 2717 */
                    expiration_days = 90L;

                    break;


                case 2433889:
                    /* 2721 */
                    mountid = 80011194;
                    /* 2722 */
                    expiration_days = 90L;

                    break;


                case 2433888:
                    /* 2726 */
                    mountid = 80011199;
                    /* 2727 */
                    expiration_days = 15L;

                    break;


                case 2433884:
                    /* 2731 */
                    mountid = 80001057;
                    /* 2732 */
                    expiration_days = 14L;

                    break;


                case 2433866:
                    /* 2736 */
                    mountid = 80011186;
                    /* 2737 */
                    expiration_days = 90L;

                    break;


                case 2433865:
                    /* 2741 */
                    mountid = 80011136;
                    /* 2742 */
                    expiration_days = 90L;

                    break;


                case 2433864:
                    /* 2746 */
                    mountid = 80011184;
                    /* 2747 */
                    expiration_days = 90L;

                    break;


                case 2433863:
                    /* 2751 */
                    mountid = 80011183;
                    /* 2752 */
                    expiration_days = 90L;

                    break;


                case 2433862:
                    /* 2756 */
                    mountid = 80011182;
                    /* 2757 */
                    expiration_days = 90L;

                    break;


                case 2433861:
                    /* 2761 */
                    mountid = 80011181;
                    /* 2762 */
                    expiration_days = 90L;

                    break;


                case 2433860:
                    /* 2766 */
                    mountid = 80011180;
                    /* 2767 */
                    expiration_days = 90L;

                    break;


                case 2433805:
                    /* 2771 */
                    mountid = 80011109;
                    /* 2772 */
                    expiration_days = -1L;

                    break;


                case 2433729:
                    /* 2776 */
                    mountid = 80011025;
                    /* 2777 */
                    expiration_days = -1L;

                    break;


                case 2433718:
                    /* 2781 */
                    mountid = 80001019;
                    /* 2782 */
                    expiration_days = -1L;

                    break;


                case 2433707:
                    /* 2786 */
                    mountid = 80001244;
                    /* 2787 */
                    expiration_days = -1L;

                    break;


                case 2433659:
                    /* 2791 */
                    mountid = 80001703;
                    /* 2792 */
                    expiration_days = 30L;

                    break;


                case 2433658:
                    /* 2796 */
                    mountid = 80001703;
                    /* 2797 */
                    expiration_days = 30L;

                    break;


                case 2433603:
                    /* 2801 */
                    mountid = 80001244;
                    /* 2802 */
                    expiration_days = 30L;

                    break;


                case 2433567:
                    /* 2806 */
                    mountid = 80001191;
                    /* 2807 */
                    expiration_days = 30L;

                    break;


                case 2433566:
                    /* 2811 */
                    mountid = 80001190;
                    /* 2812 */
                    expiration_days = 30L;

                    break;


                case 2433565:
                    /* 2816 */
                    mountid = 80001189;
                    /* 2817 */
                    expiration_days = 30L;

                    break;


                case 2433564:
                    /* 2821 */
                    mountid = 80001188;
                    /* 2822 */
                    expiration_days = 30L;

                    break;


                case 2433513:
                    /* 2826 */
                    mountid = 80001025;
                    /* 2827 */
                    expiration_days = 7L;

                    break;


                case 2433461:
                    /* 2831 */
                    mountid = 80001645;
                    /* 2832 */
                    expiration_days = -1L;

                    break;


                case 2433460:
                    /* 2836 */
                    mountid = 80001644;
                    /* 2837 */
                    expiration_days = -1L;

                    break;


                case 2433459:
                    /* 2841 */
                    mountid = 80001504;
                    /* 2842 */
                    expiration_days = -1L;

                    break;


                case 2433458:
                    /* 2846 */
                    mountid = 80001029;
                    /* 2847 */
                    expiration_days = -1L;

                    break;


                case 2433454:
                    /* 2851 */
                    mountid = 80001023;
                    /* 2852 */
                    expiration_days = 7L;

                    break;


                case 2433406:
                    /* 2856 */
                    mountid = 80001640;
                    /* 2857 */
                    expiration_days = 30L;

                    break;


                case 2433405:
                    /* 2861 */
                    mountid = 80001639;
                    /* 2862 */
                    expiration_days = 30L;

                    break;


                case 2433325:
                    /* 2866 */
                    mountid = 80011139;
                    /* 2867 */
                    expiration_days = 90L;

                    break;


                case 2433324:
                    /* 2871 */
                    mountid = 80001022;
                    /* 2872 */
                    expiration_days = 30L;

                    break;


                case 2433006:
                    /* 2876 */
                    mountid = 80011062;
                    /* 2877 */
                    expiration_days = 30L;

                    break;


                case 2432989:
                    /* 2881 */
                    mountid = 80001410;
                    /* 2882 */
                    expiration_days = 30L;

                    break;


                case 2432835:
                    /* 2886 */
                    mountid = 80011095;
                    /* 2887 */
                    expiration_days = 30L;

                    break;


                case 2432821:
                    /* 2891 */
                    mountid = 80011094;
                    /* 2892 */
                    expiration_days = -1L;

                    break;


                case 2432820:
                    /* 2896 */
                    mountid = 80011093;
                    /* 2897 */
                    expiration_days = -1L;

                    break;


                case 2432736:
                    /* 2901 */
                    mountid = 80001551;
                    /* 2902 */
                    expiration_days = 90L;

                    break;


                case 2432724:
                    /* 2906 */
                    mountid = 80001549;
                    /* 2907 */
                    expiration_days = 90L;

                    break;







                case 2432646:
                    /* 2916 */
                    mountid = 80001532;
                    /* 2917 */
                    expiration_days = 90L;

                    break;


                case 2432635:
                    /* 2921 */
                    mountid = 80001517;
                    /* 2922 */
                    expiration_days = 90L;

                    break;


                case 2432437:
                    /* 2926 */
                    mountid = 80011025;
                    /* 2927 */
                    expiration_days = -1L;

                    break;


                case 2432243:
                    /* 2931 */
                    mountid = 80001026;
                    /* 2932 */
                    expiration_days = 30L;

                    break;


                case 2432191:
                    /* 2936 */
                    mountid = 80001196;
                    /* 2937 */
                    expiration_days = -1L;

                    break;


                case 2432190:
                    /* 2941 */
                    mountid = 80001166;
                    /* 2942 */
                    expiration_days = -1L;

                    break;


                case 2432189:
                    /* 2946 */
                    mountid = 80001329;
                    /* 2947 */
                    expiration_days = -1L;

                    break;


                case 2432170:
                    /* 2951 */
                    mountid = 80001261;
                    /* 2952 */
                    expiration_days = 90L;

                    break;


                case 2432110:
                    /* 2956 */
                    mountid = 80001222;
                    /* 2957 */
                    expiration_days = -1L;

                    break;


                case 2432106:
                    /* 2961 */
                    mountid = 80001221;
                    /* 2962 */
                    expiration_days = 365L;

                    break;


                case 2432105:
                    /* 2966 */
                    mountid = 80001220;
                    /* 2967 */
                    expiration_days = 365L;

                    break;


                case 2432104:
                    /* 2971 */
                    mountid = 80001290;
                    /* 2972 */
                    expiration_days = 90L;

                    break;


                case 2432100:
                    /* 2976 */
                    mountid = 80001335;
                    /* 2977 */
                    expiration_days = -1L;

                    break;


                case 2432086:
                    /* 2981 */
                    mountid = 80001356;
                    /* 2982 */
                    expiration_days = 90L;

                    break;


                case 2432008:
                    /* 2986 */
                    mountid = 80001345;
                    /* 2987 */
                    expiration_days = 1L;

                    break;


                case 2431951:
                    /* 2991 */
                    mountid = 80001293;
                    /* 2992 */
                    expiration_days = 172800000L;

                    break;


                case 2431856:
                    /* 2996 */
                    mountid = 80001304;
                    /* 2997 */
                    expiration_days = -1L;

                    break;


                case 2431800:
                    /* 3001 */
                    mountid = 80001303;
                    /* 3002 */
                    expiration_days = 90L;

                    break;


                case 2431799:
                    /* 3006 */
                    mountid = 80001302;
                    /* 3007 */
                    expiration_days = -1L;

                    break;


                case 2431798:
                    /* 3011 */
                    mountid = 80001301;
                    /* 3012 */
                    expiration_days = 90L;

                    break;


                case 2431797:
                    /* 3016 */
                    mountid = 80001300;
                    /* 3017 */
                    expiration_days = -1L;

                    break;


                case 2431779:
                    /* 3021 */
                    mountid = 80001290;
                    /* 3022 */
                    expiration_days = 90L;

                    break;


                case 2431778:
                    /* 3026 */
                    mountid = 80001294;
                    /* 3027 */
                    expiration_days = 90L;

                    break;


                case 2431777:
                    /* 3031 */
                    mountid = 80011000;
                    /* 3032 */
                    expiration_days = 90L;

                    break;


                case 2431764:
                    /* 3036 */
                    mountid = 80001294;
                    /* 3037 */
                    expiration_days = -1L;

                    break;


                case 2431760:
                    /* 3041 */
                    mountid = 80001291;
                    /* 3042 */
                    expiration_days = 30L;

                    break;


                case 2431528:
                    /* 3046 */
                    mountid = 80011175;
                    /* 3047 */
                    expiration_days = 30L;

                    break;


                case 2431527:
                    /* 3051 */
                    mountid = 80001243;
                    /* 3052 */
                    expiration_days = 30L;

                    break;


                case 2431506:
                    /* 3056 */
                    mountid = 80001020;
                    /* 3057 */
                    expiration_days = 30L;

                    break;


                case 2431505:
                    /* 3061 */
                    mountid = 80001119;
                    /* 3062 */
                    expiration_days = 30L;

                    break;


                case 2431504:
                    /* 3066 */
                    mountid = 80001111;
                    /* 3067 */
                    expiration_days = 30L;

                    break;


                case 2431503:
                    /* 3071 */
                    mountid = 80001030;
                    /* 3072 */
                    expiration_days = 30L;

                    break;


                case 2431502:
                    /* 3076 */
                    mountid = 80001005;
                    /* 3077 */
                    expiration_days = 30L;

                    break;


                case 2431501:
                    /* 3081 */
                    mountid = 80001003;
                    /* 3082 */
                    expiration_days = 30L;

                    break;


                case 2431500:
                    /* 3086 */
                    mountid = 80001018;
                    /* 3087 */
                    expiration_days = 30L;

                    break;


                case 2431499:
                    /* 3091 */
                    mountid = 80001009;
                    /* 3092 */
                    expiration_days = 30L;

                    break;


                case 2431498:
                    /* 3096 */
                    mountid = 80011289;
                    /* 3097 */
                    expiration_days = 30L;

                    break;


                case 2431497:
                    /* 3101 */
                    mountid = 80001004;
                    /* 3102 */
                    expiration_days = 30L;

                    break;


                case 2431496:
                    /* 3106 */
                    mountid = 80001026;
                    /* 3107 */
                    expiration_days = 30L;

                    break;


                case 2431495:
                    /* 3111 */
                    mountid = 80001025;
                    /* 3112 */
                    expiration_days = 30L;

                    break;


                case 2431494:
                    /* 3116 */
                    mountid = 80001015;
                    /* 3117 */
                    expiration_days = 30L;

                    break;


                case 2431493:
                    /* 3121 */
                    mountid = 80001013;
                    /* 3122 */
                    expiration_days = 30L;

                    break;


                case 2431492:
                    /* 3126 */
                    mountid = 80001006;
                    /* 3127 */
                    expiration_days = 30L;

                    break;


                case 2431491:
                    /* 3131 */
                    mountid = 80001021;
                    /* 3132 */
                    expiration_days = 30L;

                    break;


                case 2431490:
                    /* 3136 */
                    mountid = 80001199;
                    /* 3137 */
                    expiration_days = 30L;

                    break;


                case 2431458:
                    /* 3141 */
                    mountid = 80001243;
                    /* 3142 */
                    expiration_days = -1L;

                    break;


                case 2431454:
                    /* 3146 */
                    mountid = 80001241;
                    /* 3147 */
                    expiration_days = -1L;

                    break;


                case 2431452:
                    /* 3151 */
                    mountid = 80001250;
                    /* 3152 */
                    expiration_days = -1L;

                    break;


                case 2431422:
                    /* 3156 */
                    mountid = 80001237;
                    /* 3157 */
                    expiration_days = -1L;

                    break;


                case 2431415:
                    /* 3161 */
                    mountid = 80001241;
                    /* 3162 */
                    expiration_days = -1L;

                    break;


                case 2431393:
                    /* 3166 */
                    mountid = 80011028;
                    /* 3167 */
                    expiration_days = -1L;

                    break;


                case 2431392:
                    /* 3171 */
                    mountid = 80011028;
                    /* 3172 */
                    expiration_days = 365L;

                    break;


                case 2431391:
                    /* 3176 */
                    mountid = 80011028;
                    /* 3177 */
                    expiration_days = 90L;

                    break;


                case 2431372:
                    /* 3181 */
                    mountid = 80011028;
                    /* 3182 */
                    expiration_days = 30L;

                    break;


                case 2431371:
                    /* 3186 */
                    mountid = 80001175;
                    /* 3187 */
                    expiration_days = 30L;

                    break;


                case 2431370:
                    /* 3191 */
                    mountid = 80001174;
                    /* 3192 */
                    expiration_days = 30L;

                    break;


                case 2431369:
                    /* 3196 */
                    mountid = 80001173;
                    /* 3197 */
                    expiration_days = 30L;

                    break;


                case 2431368:
                    /* 3201 */
                    mountid = 80001191;
                    /* 3202 */
                    expiration_days = 30L;

                    break;


                case 2431367:
                    /* 3206 */
                    mountid = 80001189;
                    /* 3207 */
                    expiration_days = 30L;

                    break;


                case 2431366:
                    /* 3211 */
                    mountid = 80001187;
                    /* 3212 */
                    expiration_days = 30L;

                    break;


                case 2431365:
                    /* 3216 */
                    mountid = 80001190;
                    /* 3217 */
                    expiration_days = 30L;

                    break;


                case 2431364:
                    /* 3221 */
                    mountid = 80001188;
                    /* 3222 */
                    expiration_days = 30L;

                    break;


                case 2431267:
                    /* 3226 */
                    mountid = 80001228;
                    /* 3227 */
                    expiration_days = -1L;

                    break;


                case 2431134:
                    /* 3231 */
                    mountid = 80001221;
                    /* 3232 */
                    expiration_days = 7L;

                    break;


                case 2431133:
                    /* 3236 */
                    mountid = 80001220;
                    /* 3237 */
                    expiration_days = 7L;

                    break;


                case 2431044:
                    /* 3241 */
                    mountid = 80001198;
                    /* 3242 */
                    expiration_days = 30L;

                    break;


                case 2430991:
                    /* 3246 */
                    mountid = 80001174;
                    /* 3247 */
                    expiration_days = 30L;

                    break;


                case 2430948:
                    /* 3251 */
                    mountid = 80001190;
                    /* 3252 */
                    expiration_days = -1L;

                    break;


                case 2430937:
                    /* 3256 */
                    mountid = 80001193;
                    /* 3257 */
                    expiration_days = -1L;

                    break;


                case 2430936:
                    /* 3261 */
                    mountid = 80001192;
                    /* 3262 */
                    expiration_days = -1L;

                    break;


                case 2430935:
                    /* 3266 */
                    mountid = 80001191;
                    /* 3267 */
                    expiration_days = -1L;

                    break;


                case 2430934:
                    /* 3271 */
                    mountid = 80001190;
                    /* 3272 */
                    expiration_days = -1L;

                    break;


                case 2430933:
                    /* 3276 */
                    mountid = 80001189;
                    /* 3277 */
                    expiration_days = -1L;

                    break;


                case 2430932:
                    /* 3281 */
                    mountid = 80001188;
                    /* 3282 */
                    expiration_days = -1L;

                    break;


                case 2430931:
                    /* 3286 */
                    mountid = 80001187;
                    /* 3287 */
                    expiration_days = 30L;

                    break;


                case 2430930:
                    /* 3291 */
                    mountid = 80001186;
                    /* 3292 */
                    expiration_days = 30L;

                    break;


                case 2430929:
                    /* 3296 */
                    mountid = 80001185;
                    /* 3297 */
                    expiration_days = 30L;

                    break;


                case 2430928:
                    /* 3301 */
                    mountid = 80001184;
                    /* 3302 */
                    expiration_days = 30L;

                    break;


                case 2430927:
                    /* 3306 */
                    mountid = 80001183;
                    /* 3307 */
                    expiration_days = 30L;

                    break;


                case 2430918:
                    /* 3311 */
                    mountid = 80001181;
                    /* 3312 */
                    expiration_days = 172800000L;

                    break;


                case 2430908:
                    /* 3316 */
                    mountid = 80001175;
                    /* 3317 */
                    expiration_days = 30L;

                    break;


                case 2430907:
                    /* 3321 */
                    mountid = 80001174;
                    /* 3322 */
                    expiration_days = 30L;

                    break;


                case 2430906:
                    /* 3326 */
                    mountid = 80001173;
                    /* 3327 */
                    expiration_days = 30L;

                    break;


                case 2430871:
                    /* 3331 */
                    mountid = 80001006;
                    /* 3332 */
                    expiration_days = 7L;

                    break;


                case 2430794:
                    /* 3336 */
                    mountid = 80001163;
                    /* 3337 */
                    expiration_days = 7L;

                    break;


                case 2430728:
                    /* 3341 */
                    mountid = 80001149;
                    /* 3342 */
                    expiration_days = 30L;

                    break;


                case 2430727:
                    /* 3346 */
                    mountid = 80001148;
                    /* 3347 */
                    expiration_days = 30L;

                    break;


                case 2430726:
                    /* 3351 */
                    mountid = 80001144;
                    /* 3352 */
                    expiration_days = 30L;

                    break;


                case 2430719:
                    /* 3356 */
                    mountid = 80001025;
                    /* 3357 */
                    expiration_days = 30L;

                    break;


                case 2430718:
                    /* 3361 */
                    mountid = 80001013;
                    /* 3362 */
                    expiration_days = 30L;

                    break;


                case 2430717:
                    /* 3366 */
                    mountid = 80001504;
                    /* 3367 */
                    expiration_days = 30L;

                    break;


                case 2430654:
                    /* 3371 */
                    mountid = 80001113;
                    /* 3372 */
                    expiration_days = 30L;

                    break;


                case 2430634:
                    /* 3376 */
                    mountid = 80001006;
                    /* 3377 */
                    expiration_days = 30L;

                    break;


                case 2430633:
                    /* 3381 */
                    mountid = 80001024;
                    /* 3382 */
                    expiration_days = 30L;

                    break;


                case 2430619:
                    /* 3386 */
                    mountid = 80001113;
                    /* 3387 */
                    expiration_days = 15L;

                    break;


                case 2430617:
                    /* 3391 */
                    mountid = 80001112;
                    /* 3392 */
                    expiration_days = 15L;

                    break;


                case 2430616:
                    /* 3396 */
                    mountid = 80001114;
                    /* 3397 */
                    expiration_days = 15L;

                    break;


                case 2430615:
                    /* 3401 */
                    mountid = 80001113;
                    /* 3402 */
                    expiration_days = 7L;

                    break;


                case 2430614:
                    /* 3406 */
                    mountid = 80001112;
                    /* 3407 */
                    expiration_days = 7L;

                    break;


                case 2430613:
                    /* 3411 */
                    mountid = 80001114;
                    /* 3412 */
                    expiration_days = 7L;

                    break;


                case 2430610:
                    /* 3416 */
                    mountid = 80001022;
                    /* 3417 */
                    expiration_days = 7L;

                    break;


                case 2430598:
                    /* 3421 */
                    mountid = 80001019;
                    /* 3422 */
                    expiration_days = 3L;

                    break;


                case 2430593:
                    /* 3426 */
                    mountid = 80001057;
                    /* 3427 */
                    expiration_days = 3L;

                    break;


                case 2430585:
                    /* 3431 */
                    mountid = 80001113;
                    /* 3432 */
                    expiration_days = 3L;

                    break;


                case 2430580:
                    /* 3436 */
                    mountid = 80001112;
                    /* 3437 */
                    expiration_days = 3L;

                    break;


                case 2430579:
                    /* 3441 */
                    mountid = 80001114;
                    /* 3442 */
                    expiration_days = 3L;

                    break;


                case 2430566:
                    /* 3446 */
                    mountid = 80001071;
                    /* 3447 */
                    expiration_days = 30L;

                    break;


                case 2430544:
                    /* 3451 */
                    mountid = 80001002;
                    /* 3452 */
                    expiration_days = 7L;

                    break;


                case 2430535:
                    /* 3456 */
                    mountid = 80001113;
                    /* 3457 */
                    expiration_days = 90L;

                    break;


                case 2430533:
                    /* 3461 */
                    mountid = 80001112;
                    /* 3462 */
                    expiration_days = 90L;

                    break;


                case 2430532:
                    /* 3466 */
                    mountid = 80001112;
                    /* 3467 */
                    expiration_days = -1L;

                    break;


                case 2430518:
                    /* 3471 */
                    mountid = 80001090;
                    /* 3472 */
                    expiration_days = 30L;

                    break;


                case 2430508:
                    /* 3476 */
                    mountid = 80001084;
                    /* 3477 */
                    expiration_days = 30L;

                    break;


                case 2430507:
                    /* 3481 */
                    mountid = 80001083;
                    /* 3482 */
                    expiration_days = 30L;

                    break;


                case 2430506:
                    /* 3486 */
                    mountid = 80001082;
                    /* 3487 */
                    expiration_days = 30L;

                    break;


                case 2430480:
                    /* 3491 */
                    mountid = 80001239;
                    /* 3492 */
                    expiration_days = 30L;

                    break;


                case 2430475:
                    /* 3496 */
                    mountid = 80001121;
                    /* 3497 */
                    expiration_days = 30L;

                    break;


                case 2430458:
                    /* 3501 */
                    mountid = 80001326;
                    /* 3502 */
                    expiration_days = 7L;

                    break;


                case 2430206:
                    /* 3506 */
                    mountid = 80001009;
                    /* 3507 */
                    expiration_days = 7L;

                    break;


                case 2430202:
                    /* 3511 */
                    mountid = 80001326;
                    /* 3512 */
                    expiration_days = 15L;

                    break;


                case 2430198:
                    /* 3516 */
                    mountid = 80001015;
                    /* 3517 */
                    expiration_days = 365L;

                    break;


                case 2430196:
                    /* 3521 */
                    mountid = 80001024;
                    /* 3522 */
                    expiration_days = 365L;

                    break;


                case 2430195:
                    /* 3526 */
                    mountid = 80001017;
                    /* 3527 */
                    expiration_days = 365L;

                    break;


                case 2430194:
                    /* 3531 */
                    mountid = 80001072;
                    /* 3532 */
                    expiration_days = 365L;

                    break;


                case 2430578:
                    /* 3536 */
                    mountid = 80001077;
                    /* 3537 */
                    expiration_days = 3L;

                    break;


                case 2438715:
                    /* 3541 */
                    mountid = 80002439;
                    /* 3542 */
                    expiration_days = -1L;

                    break;


                case 2438716:
                    /* 3546 */
                    mountid = 80002440;
                    /* 3547 */
                    expiration_days = 90L;

                    break;


                case 2439331:
                    /* 3551 */
                    mountid = 80002573;
                    /* 3552 */
                    expiration_days = -1L;

                    break;


                case 2439332:
                    /* 3556 */
                    mountid = 80002573;
                    /* 3557 */
                    expiration_days = 90L;

                    break;


                case 2439666:
                    /* 3561 */
                    mountid = 80002594;
                    /* 3562 */
                    expiration_days = -1L;

                    break;


                case 2439667:
                    /* 3566 */
                    mountid = 80002595;
                    /* 3567 */
                    expiration_days = -1L;

                    break;


                case 2439486:
                    /* 3571 */
                    mountid = 80002630;
                    /* 3572 */
                    expiration_days = -1L;

                    break;


                case 2439487:
                    /* 3576 */
                    mountid = 80002631;
                    /* 3577 */
                    expiration_days = 90L;

                    break;


                case 2630836:
                    /* 3581 */
                    mountid = 80011857;
                    /* 3582 */
                    expiration_days = -1L;

                    break;


                case 2630837:
                    /* 3586 */
                    mountid = 80011858;
                    /* 3587 */
                    expiration_days = 90L;

                    break;


                case 2631146:
                    /* 3591 */
                    mountid = 80011914;
                    /* 3592 */
                    expiration_days = -1L;

                    break;


                case 2439675:
                    /* 3596 */
                    mountid = 80002648;
                    /* 3597 */
                    expiration_days = -1L;

                    break;


                case 2439676:
                    /* 3601 */
                    mountid = 80002649;
                    /* 3602 */
                    expiration_days = 90L;

                    break;


                case 2631652:
                    /* 3606 */
                    mountid = 80011959;
                    /* 3607 */
                    expiration_days = -1L;

                    break;


                case 2631653:
                    /* 3611 */
                    mountid = 80011960;
                    /* 3612 */
                    expiration_days = 90L;

                    break;


                case 2631385:
                    /* 3616 */
                    mountid = 80011926;
                    /* 3617 */
                    expiration_days = -1L;

                    break;


                case 2631386:
                    /* 3621 */
                    mountid = 80011927;
                    /* 3622 */
                    expiration_days = 90L;

                    break;


                case 2631040:
                    /* 3626 */
                    mountid = 80011906;
                    /* 3627 */
                    expiration_days = -1L;

                    break;


                case 2631041:
                    /* 3631 */
                    mountid = 80011907;
                    /* 3632 */
                    expiration_days = 90L;

                    break;


                case 2631042:
                    /* 3636 */
                    mountid = 80011908;
                    /* 3637 */
                    expiration_days = -1L;

                    break;


                case 2631043:
                    /* 3641 */
                    mountid = 80011909;
                    /* 3642 */
                    expiration_days = 90L;

                    break;


                case 2631147:
                    /* 3646 */
                    mountid = 80011923;
                    /* 3647 */
                    expiration_days = -1L;

                    break;


                case 2631148:
                    /* 3651 */
                    mountid = 80011924;
                    /* 3652 */
                    expiration_days = 90L;

                    break;


                case 2631411:
                    /* 3656 */
                    mountid = 80011936;
                    /* 3657 */
                    expiration_days = -1L;

                    break;


                case 2631412:
                    /* 3661 */
                    mountid = 80011937;
                    /* 3662 */
                    expiration_days = 90L;

                    break;


                case 2631409:
                    /* 3666 */
                    mountid = 80011934;
                    /* 3667 */
                    expiration_days = -1L;

                    break;


                case 2631410:
                    /* 3671 */
                    mountid = 80011935;
                    /* 3672 */
                    expiration_days = 90L;

                    break;


                case 2631403:
                    /* 3676 */
                    mountid = 80011928;
                    /* 3677 */
                    expiration_days = -1L;

                    break;


                case 2631404:
                    /* 3681 */
                    mountid = 80011929;
                    /* 3682 */
                    expiration_days = 90L;

                    break;


                case 2631405:
                    /* 3686 */
                    mountid = 80011930;
                    /* 3687 */
                    expiration_days = -1L;

                    break;


                case 2631406:
                    /* 3691 */
                    mountid = 80011931;
                    /* 3692 */
                    expiration_days = 90L;

                    break;


                case 2631407:
                    /* 3696 */
                    mountid = 80011932;
                    /* 3697 */
                    expiration_days = -1L;

                    break;


                case 2631408:
                    /* 3701 */
                    mountid = 80011933;
                    /* 3702 */
                    expiration_days = 90L;

                    break;


                case 2631475:
                    /* 3706 */
                    mountid = 80011944;
                    /* 3707 */
                    expiration_days = -1L;

                    break;


                case 2631476:
                    /* 3711 */
                    mountid = 80011945;
                    /* 3712 */
                    expiration_days = 90L;

                    break;


                case 2630261:
                    /* 3716 */
                    mountid = 80011956;
                    /* 3717 */
                    expiration_days = -1L;

                    break;


                case 2630971:
                    /* 3721 */
                    mountid = 80011965;
                    /* 3722 */
                    expiration_days = -1L;

                    break;


                case 2631096:
                    /* 3726 */
                    mountid = 80011913;
                    /* 3727 */
                    expiration_days = -1L;

                    break;




                case 2630240:
                    /* 3733 */
                    mountid = 80002698;
                    /* 3734 */
                    expiration_days = -1L;

                    break;


                case 2439329:
                    /* 3738 */
                    mountid = 80002571;
                    /* 3739 */
                    expiration_days = -1L;

                    break;


                case 2439330:
                    /* 3743 */
                    mountid = 80002572;
                    /* 3744 */
                    expiration_days = 90L;

                    break;


                case 2439913:
                    /* 3748 */
                    mountid = 80002663;
                    /* 3749 */
                    expiration_days = -1L;

                    break;


                case 2439914:
                    /* 3753 */
                    mountid = 80002664;
                    /* 3754 */
                    expiration_days = 90L;

                    break;


                case 2439911:
                    /* 3758 */
                    mountid = 80002661;
                    /* 3759 */
                    expiration_days = -1L;

                    break;


                case 2439912:
                    /* 3763 */
                    mountid = 80002662;
                    /* 3764 */
                    expiration_days = 90L;

                    break;


                case 2439915:
                    /* 3768 */
                    mountid = 80002665;
                    /* 3769 */
                    expiration_days = -1L;

                    break;


                case 2439916:
                    /* 3773 */
                    mountid = 80002666;
                    /* 3774 */
                    expiration_days = 90L;

                    break;


                case 2439909:
                    /* 3778 */
                    mountid = 80002659;
                    /* 3779 */
                    expiration_days = -1L;

                    break;


                case 2439910:
                    /* 3783 */
                    mountid = 80002660;
                    /* 3784 */
                    expiration_days = 90L;

                    break;


                case 2439808:
                    /* 3788 */
                    mountid = 80002655;
                    /* 3789 */
                    expiration_days = -1L;

                    break;


                case 2439809:
                    /* 3793 */
                    mountid = 80002656;
                    /* 3794 */
                    expiration_days = 90L;

                    break;


                case 2439775:
                    /* 3798 */
                    mountid = 80002654;
                    /* 3799 */
                    expiration_days = -1L;

                    break;


                case 2630764:
                    /* 3803 */
                    mountid = 80002743;
                    /* 3804 */
                    expiration_days = -1L;

                    break;


                case 2630765:
                    /* 3808 */
                    mountid = 80002744;
                    /* 3809 */
                    expiration_days = -1L;

                    break;


                case 2630913:
                    /* 3813 */
                    mountid = 80002843;
                    /* 3814 */
                    expiration_days = -1L;

                    break;


                case 2630914:
                    /* 3818 */
                    mountid = 80002844;
                    /* 3819 */
                    expiration_days = 90L;

                    break;


                case 2630917:
                    /* 3823 */
                    mountid = 80002831;
                    /* 3824 */
                    expiration_days = -1L;

                    break;


                case 2630918:
                    /* 3828 */
                    mountid = 80002845;
                    /* 3829 */
                    expiration_days = -1L;

                    break;


                case 2630919:
                    /* 3833 */
                    mountid = 80002846;
                    /* 3834 */
                    expiration_days = -1L;

                    break;


                case 2630767:
                    /* 3838 */
                    mountid = 80011850;
                    /* 3839 */
                    expiration_days = -1L;

                    break;


                case 2630768:
                    /* 3843 */
                    mountid = 80011851;
                    /* 3844 */
                    expiration_days = 90L;

                    break;


                case 2630399:
                    /* 3848 */
                    mountid = 80011808;
                    /* 3849 */
                    expiration_days = -1L;

                    break;


                case 2630398:
                    /* 3853 */
                    mountid = 80011809;
                    /* 3854 */
                    expiration_days = 90L;

                    break;


                case 2630503:
                    /* 3858 */
                    mountid = 80011821;
                    /* 3859 */
                    expiration_days = -1L;

                    break;


                case 2630502:
                    /* 3863 */
                    mountid = 80011822;
                    /* 3864 */
                    expiration_days = 90L;

                    break;


                case 2630578:
                    /* 3868 */
                    mountid = 80011826;
                    /* 3869 */
                    expiration_days = -1L;

                    break;


                case 2630577:
                    /* 3873 */
                    mountid = 80011825;
                    /* 3874 */
                    expiration_days = 90L;

                    break;


                case 2630300:
                    /* 3878 */
                    mountid = 80011798;
                    /* 3879 */
                    expiration_days = -1L;

                    break;


                case 2630299:
                    /* 3883 */
                    mountid = 80011799;
                    /* 3884 */
                    expiration_days = 90L;

                    break;


                case 2630231:
                    /* 3888 */
                    mountid = 80011773;
                    /* 3889 */
                    expiration_days = -1L;

                    break;


                case 2630361:
                    /* 3893 */
                    mountid = 80011774;
                    /* 3894 */
                    expiration_days = 90L;

                    break;


                case 2630232:
                    /* 3898 */
                    mountid = 80011775;
                    /* 3899 */
                    expiration_days = -1L;

                    break;


                case 2630362:
                    /* 3903 */
                    mountid = 80011776;
                    /* 3904 */
                    expiration_days = 90L;

                    break;


                case 2630233:
                    /* 3908 */
                    mountid = 80011777;
                    /* 3909 */
                    expiration_days = -1L;

                    break;


                case 2630363:
                    /* 3913 */
                    mountid = 80011778;
                    /* 3914 */
                    expiration_days = 90L;

                    break;


                case 2630234:
                    /* 3918 */
                    mountid = 80011779;
                    /* 3919 */
                    expiration_days = -1L;

                    break;


                case 2630364:
                    /* 3923 */
                    mountid = 80011780;
                    /* 3924 */
                    expiration_days = 90L;

                    break;


                case 2630451:
                    /* 3928 */
                    mountid = 80002715;
                    /* 3929 */
                    expiration_days = -1L;

                    break;


                case 2630452:
                    /* 3933 */
                    mountid = 80002716;
                    /* 3934 */
                    expiration_days = 90L;

                    break;


                case 2630386:
                    /* 3938 */
                    mountid = 80002712;
                    /* 3939 */
                    expiration_days = -1L;

                    break;


                case 2630448:
                    /* 3943 */
                    mountid = 80002714;
                    /* 3944 */
                    expiration_days = -1L;

                    break;


                case 2439266:
                    /* 3948 */
                    mountid = 80002545;
                    /* 3949 */
                    expiration_days = -1L;

                    break;


                case 2439278:
                    /* 3953 */
                    mountid = 80002546;
                    /* 3954 */
                    expiration_days = -1L;

                    break;


                case 2439295:
                    /* 3958 */
                    mountid = 80002547;
                    /* 3959 */
                    expiration_days = -1L;

                    break;


                case 2630585:
                    /* 3963 */
                    mountid = 80011844;
                    /* 3964 */
                    expiration_days = -1L;

                    break;


                case 2630584:
                    /* 3968 */
                    mountid = 80011845;
                    /* 3969 */
                    expiration_days = 90L;

                    break;


                case 2630152:
                    /* 3973 */
                    mountid = 80011784;
                    /* 3974 */
                    expiration_days = -1L;

                    break;


                case 2630151:
                    /* 3978 */
                    mountid = 80011785;
                    /* 3979 */
                    expiration_days = 90L;

                    break;


                case 2630324:
                    /* 3983 */
                    mountid = 80011791;
                    /* 3984 */
                    expiration_days = -1L;

                    break;


                case 2439550:
                    /* 3988 */
                    mountid = 80011721;
                    /* 3989 */
                    expiration_days = -1L;

                    break;


                case 2439549:
                    /* 3993 */
                    mountid = 80011722;
                    /* 3994 */
                    expiration_days = 90L;

                    break;


                case 2437950:
                    /* 3998 */
                    mountid = 80011538;
                    /* 3999 */
                    expiration_days = -1L;

                    break;


                case 2437951:
                    /* 4003 */
                    mountid = 80011539;
                    /* 4004 */
                    expiration_days = 90L;

                    break;


                case 2435112:
                    /* 4008 */
                    mountid = 80001953;

                    /* 4010 */
                    expiration_days = -1L;

                    break;


                case 2435113:
                    /* 4014 */
                    mountid = 80001954;

                    /* 4016 */
                    expiration_days = -1L;

                    break;


                case 2435114:
                    /* 4020 */
                    mountid = 80001955;

                    /* 4022 */
                    expiration_days = -1L;

                    break;



                case 2436649:
                    /* 4027 */
                    mountid = 80011438;
                    /* 4028 */
                    expiration_days = 90L;

                    break;


                case 2436650:
                    /* 4032 */
                    mountid = 80011439;
                    /* 4033 */
                    expiration_days = -1L;

                    break;


                case 2436738:
                    /* 4037 */
                    mountid = 80011451;
                    /* 4038 */
                    expiration_days = 90L;

                    break;


                case 2436739:
                    /* 4042 */
                    mountid = 80011452;
                    /* 4043 */
                    expiration_days = -1L;

                    break;


                case 2436758:
                    /* 4047 */
                    mountid = 80011453;
                    /* 4048 */
                    expiration_days = 90L;

                    break;


                case 2436759:
                    /* 4052 */
                    mountid = 80011454;
                    /* 4053 */
                    expiration_days = -1L;

                    break;


                case 2437045:
                    /* 4057 */
                    mountid = 80011486;
                    /* 4058 */
                    expiration_days = 90L;

                    break;


                case 2437046:
                    /* 4062 */
                    mountid = 80011487;
                    /* 4063 */
                    expiration_days = -1L;

                    break;


                case 2437047:
                    /* 4067 */
                    mountid = 80011488;
                    /* 4068 */
                    expiration_days = 90L;

                    break;


                case 2437048:
                    /* 4072 */
                    mountid = 80011489;
                    /* 4073 */
                    expiration_days = -1L;

                    break;


                case 2437272:
                    /* 4077 */
                    mountid = 80011500;
                    /* 4078 */
                    expiration_days = 90L;

                    break;


                case 2437273:
                    /* 4082 */
                    mountid = 80011501;
                    /* 4083 */
                    expiration_days = -1L;

                    break;


                case 2437486:
                    /* 4087 */
                    mountid = 80011502;
                    /* 4088 */
                    expiration_days = 90L;

                    break;


                case 2437487:
                    /* 4092 */
                    mountid = 80011503;
                    /* 4093 */
                    expiration_days = -1L;

                    break;


                case 2437519:
                    /* 4097 */
                    mountid = 80011506;
                    /* 4098 */
                    expiration_days = 90L;

                    break;


                case 2437520:
                    /* 4102 */
                    mountid = 80011507;
                    /* 4103 */
                    expiration_days = -1L;

                    break;














                default:
                    /* 4119 */
                    if (ItemConstants.isDamageSkinItem(toUse.getItemId())) {
                        /* 4120 */
                        if (!JobConstants.is神之子(chr.getJob())) {
                            /* 4121 */
                            int sitemid = toUse.getItemId();
                            /* 4122 */
                            int skinnum = ((Integer) ii.getDamageSkinBox().get(Integer.valueOf(sitemid))).intValue();
                            /* 4123 */
                            if (skinnum == -1) {
                                /* 4124 */
                                chr.dropMessage(-9, "出现未知错误");

                                break;

                            }
                            /* 4127 */
                            chr.dropMessage(-1, "伤害皮肤已变更。");
                            /* 4128 */
                            c.getPlayer().changeDamageSkin(skinnum);
                            /* 4129 */
                            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                            break;

                        }
                        /* 4131 */
                        chr.dropMessage(-9, "神之子无法套用伤害字型。");


                        break;

                    }
                    /* 4135 */
                    ItemScriptManager.getInstance().start(c, info.getNpc(), toUse);

                    break;

            }

        }
        /* 4139 */
        if (mountid > 0) {

            /* 4141 */
            mountid = (mountid > 80001000) ? mountid : PlayerStats.getSkillByJob(mountid, c.getPlayer().getJob());
            /* 4142 */
            int fk = GameConstants.getMountItem(mountid, c.getPlayer());

            /* 4144 */
            if (fk > 0 && mountid < 80001000) {
                /* 4145 */
                for (int i = 80001001; i < 80001999; i++) {
                    /* 4146 */
                    Skill skill = SkillFactory.getSkill(i);
                    /* 4147 */
                    if (skill != null && GameConstants.getMountItem(skill.getId(), c.getPlayer()) == fk) {
                        /* 4148 */
                        mountid = i;


                        break;

                    }

                }

            }
            /* 4154 */
            if (c.getPlayer().getSkillLevel(mountid) > 0) {
                /* 4155 */
                c.getPlayer().dropMessage(1, "您已经拥有了[" + SkillFactory.getSkill(mountid).getName() + "]这个骑宠的技能，无法使用该道具。");
                /* 4156 */
            } else if (SkillFactory.getSkill(mountid) == null || GameConstants.getMountItem(mountid, c.getPlayer()) == 0) {
                /* 4157 */
                c.getPlayer().dropMessage(1, "您无法使用这个骑宠的技能.");
                /* 4158 */
            } else if (expiration_days > 0L) {
                /* 4159 */
                MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                /* 4160 */
                c.getPlayer().changeSingleSkillLevel(SkillFactory.getSkill(mountid), 1, (byte) 1, System.currentTimeMillis() + expiration_days * 24L * 60L * 60L * 1000L);
                /* 4161 */
                c.getPlayer().dropMessage(1, "恭喜您获得[" + SkillFactory.getSkill(mountid).getName() + "]骑宠技能 " + expiration_days + " 权。");
                /* 4162 */
            } else if (expiration_days == -1L) {
                /* 4163 */
                MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);
                /* 4164 */
                c.getPlayer().changeSingleSkillLevel(SkillFactory.getSkill(mountid), 1, (byte) 1, -1L);
                /* 4165 */
                c.getPlayer().dropMessage(1, "恭喜您获得[" + SkillFactory.getSkill(mountid).getName() + "]骑宠技能永久权。");

            }

        }




        /* 4172 */
        c.announce(MaplePacketCreator.enableActions());

    }






    public static void UseSummonBag(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 4179 */
        if (!chr.isAlive() || chr.hasBlockedInventory() || chr.inPVP()) {
            /* 4180 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 4183 */
        c.getPlayer().updateTick(slea.readInt());
        /* 4184 */
        short slot = slea.readShort();
        /* 4185 */
        int itemId = slea.readInt();
        /* 4186 */
        Item toUse = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /* 4187 */
        if (toUse != null && toUse.getQuantity() >= 1 && toUse.getItemId() == itemId && (c.getPlayer().getMapId() < 910000000 || c.getPlayer().getMapId() > 910000022)) {
            /* 4188 */
            Map<String, Integer> toSpawn = MapleItemInformationProvider.getInstance().getItemBaseInfo(itemId);
            /* 4189 */
            if (toSpawn == null) {
                /* 4190 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4193 */
            MapleMonster ht = null;
            /* 4194 */
            int type = 0;
            /* 4195 */
            for (Map.Entry<String, Integer> i : toSpawn.entrySet()) {
                /* 4196 */
                if (((String) i.getKey()).startsWith("mob") && Randomizer.nextInt(99) <= ((Integer) i.getValue()).intValue()) {
                    /* 4197 */
                    ht = MapleLifeFactory.getMonster(Integer.parseInt(((String) i.getKey()).substring(3)));
                    /* 4198 */
                    chr.getMap().spawnMonster_sSack(ht, chr.getPosition(), type);

                }

            }
            /* 4201 */
            if (ht == null) {
                /* 4202 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4205 */
            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);

        }
        /* 4207 */
        c.announce(MaplePacketCreator.enableActions());

    }







    public static void UseTreasureChest(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {

        int reward, keyIDforRemoval;

        String box, key;

        int price;
        /* 4218 */
        short slot = slea.readShort();
        /* 4219 */
        int itemid = slea.readInt();
        /* 4220 */
        boolean useCash = (slea.readByte() > 0);
        /* 4221 */
        Item toUse = chr.getInventory(MapleInventoryType.ETC).getItem(slot);
        /* 4222 */
        if (toUse == null || toUse.getQuantity() <= 0 || toUse.getItemId() != itemid || chr.hasBlockedInventory()) {
            /* 4223 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 4226 */
        if (!chr.getCheatTracker().canMZD() && !chr.isGM()) {
            /* 4227 */
            chr.dropMessage(5, "你需要等待5秒之后才能使用谜之蛋.");
            /* 4228 */
            c.announce(MaplePacketCreator.enableActions());



            return;

        }


        /* 4235 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /* 4236 */
        switch (toUse.getItemId()) {

            case 4280000:
                /* 4238 */
                reward = RandomRewards.getGoldBoxReward();
                /* 4239 */
                keyIDforRemoval = 5490000;
                /* 4240 */
                box = "永恒的谜之蛋";
                /* 4241 */
                key = "永恒的热度";
                /* 4242 */
                price = 800;

                break;

            case 4280001:
                /* 4245 */
                reward = RandomRewards.getSilverBoxReward();
                /* 4246 */
                keyIDforRemoval = 5490001;
                /* 4247 */
                box = "重生的谜之蛋";
                /* 4248 */
                key = "重生的热度";
                /* 4249 */
                price = 500;

                break;

            default:

                return;

        }
        /* 4254 */
        int amount = 1;
        /* 4255 */
        switch (reward) {

            case 2000004:
                /* 4257 */
                amount = 200;

                break;

            case 2000005:
                /* 4260 */
                amount = 100;

                break;

        }
        /* 4263 */
        if (useCash && chr.getCSPoints(2) < price) {
            /* 4264 */
            chr.dropMessage(1, "抵用券不足" + price + "点，请到商城购买“抵用券兑换包”即可充值抵用券！");
            /* 4265 */
            c.announce(MaplePacketCreator.enableActions());
            /* 4266 */
        } else if (chr.getInventory(MapleInventoryType.CASH).countById(keyIDforRemoval) < 0) {
            /* 4267 */
            chr.dropMessage(1, "孵化" + box + "需要" + key + "，请到商城购买！");
            /* 4268 */
            c.announce(MaplePacketCreator.enableActions());
            /* 4269 */
        } else if (chr.getInventory(MapleInventoryType.CASH).countById(keyIDforRemoval) > 0 || (useCash && chr.getCSPoints(2) > price)) {
            /* 4270 */
            Item item = MapleInventoryManipulator.addbyId_Gachapon(c, reward, (short) amount, "从 " + box + " 中获得时间: " + DateUtil.getNowTime());
            /* 4271 */
            if (item == null) {
                /* 4272 */
                chr.dropMessage(1, "孵化失败，请重试一次。");
                /* 4273 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4276 */
            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.ETC, slot, (short) 1, true);
            /* 4277 */
            if (useCash) {
                /* 4278 */
                chr.modifyCSPoints(2, -price, true);

            } else {
                /* 4280 */
                MapleInventoryManipulator.removeById(c, MapleInventoryType.CASH, keyIDforRemoval, 1, true, false);

            }
            /* 4282 */
            c.announce(MaplePacketCreator.getShowItemGain(reward, (short) amount, true));
            /* 4283 */
            byte rareness = GameConstants.gachaponRareItem(item.getItemId());
            /* 4284 */
            if (rareness > 0) {
                /* 4285 */
                WorldBroadcastService.getInstance().broadcastMessage(MaplePacketCreator.getGachaponMega(c.getPlayer().getName(), " : 从" + box + "中获得{" + ii.getName(item.getItemId()) + "}！大家一起恭喜他（她）吧！！！！", item, rareness, c.getChannel()));

            }

        } else {
            /* 4288 */
            chr.dropMessage(5, "孵化" + box + "失败，进检查是否有" + key + "或者抵用卷大于" + price + "点。");
            /* 4289 */
            c.announce(MaplePacketCreator.enableActions());

        }

    }






    public static void Pickup_Player(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 4297 */
        if (c.getPlayer().hasBlockedInventory()) {

            return;

        }

        /* 4301 */
        if (c.getChannelServer().isShutdown()) {
            /* 4302 */
            chr.dropMessage(1, "服务器即将关闭维护，暂时无法进行道具捡取。");
            /* 4303 */
            c.getSession().write(MaplePacketCreator.enableActions());


            return;

        }
        /* 4307 */
        chr.updateTick(slea.readInt());
        /* 4308 */
        c.getPlayer().setScrolledPosition((short) 0);
        /* 4309 */
        slea.skip(1);
        /* 4310 */
        Point Client_Reportedpos = slea.readPos();
        /* 4311 */
        if (chr == null || chr.getMap() == null) {

            return;

        }
        /* 4314 */
        MapleMapObject ob = chr.getMap().getMapObject(slea.readInt(), MapleMapObjectType.ITEM);
        /* 4315 */
        if (ob == null) {
            /* 4316 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 4319 */
        MapleMapItem mapitem = (MapleMapItem) ob;
        /* 4320 */
        Lock lock = mapitem.getLock();
        /* 4321 */
        lock.lock();

        try {
            /* 4323 */
            if (mapitem.isPickedUp()) {
                /* 4324 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4327 */
            if (mapitem.getQuest() > 0 && chr.getQuestStatus(mapitem.getQuest()) != 1) {
                /* 4328 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4331 */
            if (mapitem.getOwner() != chr.getId() && ((!mapitem.isPlayerDrop() && mapitem.getDropType() == 0) || (mapitem.isPlayerDrop() && chr.getMap().getEverlast()))) {
                /* 4332 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4335 */
            if (!mapitem.isPlayerDrop() && mapitem.getDropType() == 1 && mapitem.getOwner() != chr.getId() && (chr.getParty() == null || chr.getParty().getMemberById(mapitem.getOwner()) == null)) {
                /* 4336 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4339 */
            double Distance = Client_Reportedpos.distanceSq(mapitem.getPosition());
            /* 4340 */
            if (Distance > 5000.0D && (mapitem.getMeso() > 0 || mapitem.getItemId() != 4001025)) {
                /* 4341 */
                chr.getCheatTracker().checkPickup(20, false);

                /* 4343 */
                WorldBroadcastService.getInstance().broadcastGMMessage(MaplePacketCreator.serverNotice(6, "[GM消息] " + chr.getName() + " ID: " + chr.getId() + " (等级 " + chr.getLevel() + ") 全屏捡物。地图ID: " + chr.getMapId() + " 范围: " + Distance));
                /* 4344 */
            } else if (chr.getPosition().distanceSq(mapitem.getPosition()) > 640000.0D) {
                /* 4345 */
                chr.getCheatTracker().checkPickup(10, false);

                /* 4347 */
                WorldBroadcastService.getInstance().broadcastGMMessage(MaplePacketCreator.serverNotice(6, "[GM消息] " + chr.getName() + " ID: " + chr.getId() + " (等级 " + chr.getLevel() + ") 全屏捡物。地图ID: " + chr.getMapId() + " 范围: " + Distance));

            }
            /* 4349 */
            if (mapitem.getMeso() > 0) {
                /* 4350 */
                if (chr.getParty() != null && mapitem.getOwner() != chr.getId()) {
                    /* 4351 */
                    List<MapleCharacter> toGive = new LinkedList<>();
                    /* 4352 */
                    int splitMeso = mapitem.getMeso() * 40 / 100;
                    /* 4353 */
                    for (MaplePartyCharacter z : chr.getParty().getMembers()) {
                        /* 4354 */
                        MapleCharacter m = chr.getMap().getCharacterById(z.getId());
                        /* 4355 */
                        if (m != null && m.getId() != chr.getId()) {
                            /* 4356 */
                            toGive.add(m);

                        }

                    }
                    /* 4359 */
                    for (MapleCharacter m : toGive) {
                        /* 4360 */
                        if (m.getMeso() >= ServerConfig.CHANNEL_PLAYER_MAXMESO) {
                            /* 4361 */
                            m.getClient().announce(MaplePacketCreator.enableActions());

                            return;

                        }
                        /* 4364 */
                        m.gainMeso((splitMeso / toGive.size() + ((m.getStat()).hasPartyBonus ? (int) (mapitem.getMeso() / 20.0D) : 0)), true);

                    }
                    /* 4366 */
                    if (chr.getMeso() >= ServerConfig.CHANNEL_PLAYER_MAXMESO) {
                        /* 4367 */
                        c.announce(MaplePacketCreator.enableActions());

                        return;

                    }
                    /* 4370 */
                    chr.gainMeso((mapitem.getMeso() - splitMeso), true);

                } else {
                    /* 4372 */
                    if (chr.getMeso() >= ServerConfig.CHANNEL_PLAYER_MAXMESO) {
                        /* 4373 */
                        c.announce(MaplePacketCreator.enableActions());

                        return;

                    }
                    /* 4376 */
                    chr.gainMeso(mapitem.getMeso(), true);

                }
                /* 4378 */
                removeItem(chr, mapitem, ob);
                /* 4379 */
            } else if (MapleItemInformationProvider.getInstance().isPickupBlocked(mapitem.getItemId())) {
                /* 4380 */
                c.announce(MaplePacketCreator.enableActions());
                /* 4381 */
                chr.dropMessage(5, "这个道具无法捡取.");
                /* 4382 */
            } else if (chr.inPVP() && Integer.parseInt(chr.getEventInstance().getProperty("ice")) == chr.getId()) {
                /* 4383 */
                c.announce(InventoryPacket.getInventoryFull());
                /* 4384 */
                c.announce(InventoryPacket.getShowInventoryFull());
                /* 4385 */
                c.announce(MaplePacketCreator.enableActions());
                /* 4386 */
            } else if (useItem(c, mapitem)) {
                /* 4387 */
                removeItem(c.getPlayer(), mapitem, ob);
                /* 4388 */
            } else if (mapitem.getItemId() / 10000 != 291 && MapleInventoryManipulator.checkSpace(c, mapitem.getItemId(), mapitem.getItem().getQuantity(), mapitem.getItem().getOwner())) {
                /* 4389 */
                if (mapitem.getItem().getQuantity() >= 50 && mapitem.getItemId() == 2340000) {
                    /* 4390 */
                    c.setMonitored(true);

                }
                /* 4392 */
                MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
                /* 4393 */
                log.info("[道具拣取] " + c.getPlayer().getName() + " 道具:" + mapitem.getItem().getItemId() + "-" + ii.getName(mapitem.getItem().getItemId()) + " 数量:" + mapitem.getItem().getQuantity() + " 地图:" + c.getPlayer().getMapId());
                /* 4394 */
                MapleInventoryManipulator.addFromDrop(c, mapitem.getItem(), true, mapitem.getDropper() instanceof MapleMonster);
                /* 4395 */
                removeItem(chr, mapitem, ob);

            } else {
                /* 4397 */
                c.announce(InventoryPacket.getInventoryFull());
                /* 4398 */
                c.announce(InventoryPacket.getShowInventoryFull());
                /* 4399 */
                c.announce(MaplePacketCreator.enableActions());

            }

        } finally {
            /* 4402 */
            lock.unlock();

        }

    }






    public static void Pickup_Pet(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 4410 */
        if (chr == null) {

            return;

        }
        /* 4413 */
        if (c.getPlayer().hasBlockedInventory() || c.getPlayer().inPVP()) {

            return;

        }
        /* 4416 */
        c.getPlayer().setScrolledPosition((short) 0);
        /* 4417 */
        byte petz = (byte) slea.readInt();
        /* 4418 */
        MaplePet pet = chr.getSpawnPet(petz);
        /* 4419 */
        slea.skip(1);
        /* 4420 */
        chr.updateTick(slea.readInt());
        /* 4421 */
        Point Client_Reportedpos = slea.readPos();
        /* 4422 */
        MapleMapObject ob = chr.getMap().getMapObject(slea.readInt(), MapleMapObjectType.ITEM);
        /* 4423 */
        if (ob == null || pet == null) {

            return;

        }
        /* 4426 */
        MapleMapItem mapitem = (MapleMapItem) ob;
        /* 4427 */
        Lock lock = mapitem.getLock();
        /* 4428 */
        lock.lock();

        try {
            /* 4430 */
            if (mapitem.isPickedUp()) {
                /* 4431 */
                c.announce(InventoryPacket.getInventoryFull());

                return;

            }
            /* 4434 */
            if (mapitem.getOwner() != chr.getId() && mapitem.isPlayerDrop()) {

                return;

            }
            /* 4437 */
            if (mapitem.getOwner() != chr.getId() && ((!mapitem.isPlayerDrop() && mapitem.getDropType() == 0) || (mapitem.isPlayerDrop() && chr.getMap().getEverlast()))) {
                /* 4438 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4441 */
            if (!mapitem.isPlayerDrop() && mapitem.getDropType() == 1 && mapitem.getOwner() != chr.getId() && (chr.getParty() == null || chr.getParty().getMemberById(mapitem.getOwner()) == null)) {
                /* 4442 */
                c.announce(MaplePacketCreator.enableActions());

                return;

            }
            /* 4445 */
            double Distance = Client_Reportedpos.distanceSq(mapitem.getPosition());
            /* 4446 */
            if (Distance <= 10000.0D || (mapitem.getMeso() <= 0 && mapitem.getItemId() == 4001025))
                 {


                /* 4450 */
                if (pet.getPos().distanceSq(mapitem.getPosition()) > 640000.0D) ;

            }



            /* 4455 */
            if (mapitem.getMeso() > 0) {
                /* 4456 */
                if (chr.getParty() != null && mapitem.getOwner() != chr.getId()) {
                    /* 4457 */
                    List<MapleCharacter> toGive = new LinkedList<>();
                    /* 4458 */
                    int splitMeso = mapitem.getMeso() * 40 / 100;
                    /* 4459 */
                    for (MaplePartyCharacter z : chr.getParty().getMembers()) {
                        /* 4460 */
                        MapleCharacter m = chr.getMap().getCharacterById(z.getId());
                        /* 4461 */
                        if (m != null && m.getId() != chr.getId()) {
                            /* 4462 */
                            toGive.add(m);

                        }

                    }
                    /* 4465 */
                    for (MapleCharacter m : toGive) {
                        /* 4466 */
                        m.gainMeso((splitMeso / toGive.size() + ((m.getStat()).hasPartyBonus ? (int) (mapitem.getMeso() / 20.0D) : 0)), true);

                    }
                    /* 4468 */
                    chr.gainMeso((mapitem.getMeso() - splitMeso), true);

                } else {
                    /* 4470 */
                    chr.gainMeso(mapitem.getMeso(), true);

                }
                /* 4472 */
                removeItem_Pet(chr, mapitem, petz);
                /* 4473 */
            } else if (MapleItemInformationProvider.getInstance().isPickupBlocked(mapitem.getItemId()) || mapitem.getItemId() / 10000 == 291) {
                /* 4474 */
                c.announce(MaplePacketCreator.enableActions());
                /* 4475 */
            } else if (useItem(c, mapitem)) {
                /* 4476 */
                removeItem_Pet(chr, mapitem, petz);
                /* 4477 */
            } else if (MapleInventoryManipulator.checkSpace(c, mapitem.getItemId(), mapitem.getItem().getQuantity(), mapitem.getItem().getOwner())) {
                /* 4478 */
                if (mapitem.getItem().getQuantity() >= 50 && mapitem.getItemId() == 2340000) {
                    /* 4479 */
                    c.setMonitored(true);

                }
                /* 4481 */
                MapleInventoryManipulator.addFromDrop(c, mapitem.getItem(), true, mapitem.getDropper() instanceof MapleMonster, false);
                /* 4482 */
                removeItem_Pet(chr, mapitem, petz);

            }

        } finally {
            /* 4485 */
            lock.unlock();

        }

    }






    public static boolean useItem(MapleClient c, MapleMapItem mapItem) {
        /* 4493 */
        if (ItemConstants.isUse(mapItem.getItemId())) {
            /* 4494 */
            MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
            /* 4495 */
            MapleStatEffect eff = ii.getItemEffect(mapItem.getItemId());
            /* 4496 */
            if (eff == null) {
                /* 4497 */
                return false;

            }

            /* 4500 */
            if (mapItem.getItemId() / 10000 == 291) {
                /* 4501 */
                boolean area = false;
                /* 4502 */
                for (Rectangle rect : c.getPlayer().getMap().getAreas()) {
                    /* 4503 */
                    if (rect.contains(c.getPlayer().getTruePosition())) {
                        /* 4504 */
                        area = true;

                        break;

                    }

                }
                /* 4508 */
                if (!c.getPlayer().inPVP() || (c.getPlayer().getTeam() == mapItem.getItemId() - 2910000 && area)) {
                    /* 4509 */
                    return false;

                }

            }
            /* 4512 */
            int consumeval = eff.getConsume();
            /* 4513 */
            if (consumeval > 0) {
                /* 4514 */
                consumeItem(c, eff);
                /* 4515 */
                consumeItem(c, ii.getItemEffectEX(mapItem.getItemId()));
                /* 4516 */
                c.announce(MaplePacketCreator.getShowItemGain(mapItem.getItemId(), (short) 1));
                /* 4517 */
                return true;
                /* 4518 */
            }
            if (GameConstants.isDoJangConsume(mapItem.getItemId())) {
                /* 4519 */
                ii.getItemEffect(mapItem.getItemId()).applyTo(c.getPlayer());
                /* 4520 */
                c.announce(MaplePacketCreator.getShowItemGain(mapItem.getItemId(), (short) 1));
                /* 4521 */
                return true;
                /* 4522 */
            }
            if (mapItem.getItemId() == 2431174) {
                /* 4523 */
                c.getPlayer().gainHonor(Randomizer.nextInt(11));
                /* 4524 */
                c.sendEnableActions();
                /* 4525 */
                return true;
                /* 4526 */
            }
            if (mapItem.getItemId() == 2439410) {
                /* 4527 */
                c.getPlayer().gainHonor(50000);
                /* 4528 */
                c.sendEnableActions();
                /* 4529 */
                return true;

            }
            /* 4531 */
            ScriptedItem info = ii.getScriptedItemInfo(mapItem.getItemId());
            /* 4532 */
            if (info == null) {
                /* 4533 */
                return false;

            }
            /* 4535 */
            if (info.runOnPickup() && ServerConfig.RUN_ON_PICKUP) {
                /* 4536 */
                ItemScriptManager.getInstance().start(c, info.getNpc(), mapItem.getItem());
                /* 4537 */
                c.sendEnableActions();
                /* 4538 */
                return true;

            }

        }


        /* 4543 */
        return false;

    }






    public static void consumeItem(MapleClient c, MapleStatEffect eff) {
        /* 4550 */
        if (eff == null) {

            return;

        }
        /* 4553 */
        if (eff.getConsume() == 2) {
            /* 4554 */
            if (c.getPlayer().getParty() != null && c.getPlayer().isAlive()) {
                /* 4555 */
                for (MaplePartyCharacter pc : c.getPlayer().getParty().getMembers()) {
                    /* 4556 */
                    MapleCharacter chr = c.getPlayer().getMap().getCharacterById(pc.getId());
                    /* 4557 */
                    if (chr != null && chr.isAlive()) {
                        /* 4558 */
                        eff.applyTo(chr);

                    }

                }

            } else {
                /* 4562 */
                eff.applyTo(c.getPlayer());

            }
            /* 4564 */
        } else if (c.getPlayer().isAlive()) {
            /* 4565 */
            eff.applyTo(c.getPlayer());

        }

    }






    public static void removeItem_Pet(MapleCharacter chr, MapleMapItem mapitem, int pet) {
        /* 4573 */
        if (chr.getEventInstance() != null) {
            /* 4574 */
            chr.getEventInstance().pickUpItem(chr, mapitem.getItemId());

        }
        /* 4576 */
        mapitem.setPickedUp(true);
        /* 4577 */
        chr.getMap().broadcastMessage(InventoryPacket.removeItemFromMap(mapitem.getObjectId(), 5, chr.getId(), pet));
        /* 4578 */
        chr.getMap().removeMapObject((MapleMapObject) mapitem);

    }






    private static void removeItem(MapleCharacter chr, MapleMapItem mapitem, MapleMapObject ob) {
        /* 4585 */
        if (chr.getEventInstance() != null) {
            /* 4586 */
            chr.getEventInstance().pickUpItem(chr, mapitem.getItemId());

        }
        /* 4588 */
        mapitem.setPickedUp(true);
        /* 4589 */
        chr.getMap().broadcastMessage(InventoryPacket.removeItemFromMap(mapitem.getObjectId(), 2, chr.getId()), mapitem.getPosition());
        /* 4590 */
        chr.getMap().removeMapObject(ob);

    }






    public static void OwlMinerva(LittleEndianAccessor slea, MapleClient c) {
        /* 4597 */
        short slot = slea.readShort();
        /* 4598 */
        int itemid = slea.readInt();
        /* 4599 */
        Item toUse = c.getPlayer().getInventory(MapleInventoryType.USE).getItem(slot);
        /* 4600 */
        if (toUse != null && toUse.getQuantity() > 0 && toUse.getItemId() == itemid && itemid == 2310000 && !c.getPlayer().hasBlockedInventory()) {
            /* 4601 */
            int itemSearch = slea.readInt();
            /* 4602 */
            List<HiredMerchant> hms = c.getChannelServer().searchMerchant(itemSearch);
            /* 4603 */
            if (hms.size() > 0) {
                /* 4604 */
                c.announce(MaplePacketCreator.getOwlSearched(itemSearch, hms));
                /* 4605 */
                MapleInventoryManipulator.removeById(c, MapleInventoryType.USE, itemid, 1, true, false);

            } else {
                /* 4607 */
                c.getPlayer().dropMessage(1, "没有找到这个道具.");

            }
            /* 4609 */
            MapleCharacterUtil.addToItemSearch(itemSearch);

        }
        /* 4611 */
        c.announce(MaplePacketCreator.enableActions());

    }







    public static void Owl(LittleEndianAccessor slea, MapleClient c) {
        /* 4619 */
        if (c.getPlayer().getMapId() >= 910000000 && c.getPlayer().getMapId() <= 910000022) {
            /* 4620 */
            c.announce(MaplePacketCreator.getOwlOpen());

        } else {
            /* 4622 */
            c.getPlayer().dropMessage(5, "商店搜索器只能在自由市场使用.");
            /* 4623 */
            c.announce(MaplePacketCreator.enableActions());

        }

    }






    public static void OwlWarp(LittleEndianAccessor slea, MapleClient c) {
        c.announce(MaplePacketCreator.enableActions());
        if (c.getPlayer().getMapId() >= 910000000 && c.getPlayer().getMapId() <= 910000022 && !c.getPlayer().hasBlockedInventory()) {
            int id = slea.readInt();
//            int type = slea.readByte(); //未知 应该是搜索类型
            slea.skip(1);
            int map = slea.readInt();
            if (map >= 910000001 && map <= 910000022) {
                MapleMap mapp = c.getChannelServer().getMapFactory().getMap(map);
                c.getPlayer().changeMap(mapp, mapp.getPortal(0));
                HiredMerchant merchant = null;
                List<MapleMapObject> objects;
                switch (OWL_ID) {
                    case 0:
                        objects = mapp.getAllHiredMerchantsThreadsafe();
                        for (MapleMapObject ob : objects) {
                            if (ob instanceof IMaplePlayerShop) {
                                IMaplePlayerShop ips = (IMaplePlayerShop) ob;
                                if (ips instanceof HiredMerchant) {
                                    HiredMerchant merch = (HiredMerchant) ips;
                                    if (merch.getOwnerId() == id) {
                                        merchant = merch;
                                        break;
                                    }
                                }
                            }
                        }
                        break;
                    case 1:
                        objects = mapp.getAllHiredMerchantsThreadsafe();
                        for (MapleMapObject ob : objects) {
                            if (ob instanceof IMaplePlayerShop) {
                                IMaplePlayerShop ips = (IMaplePlayerShop) ob;
                                if (ips instanceof HiredMerchant) {
                                    HiredMerchant merch = (HiredMerchant) ips;
                                    if (merch.getStoreId() == id) {
                                        merchant = merch;
                                        break;
                                    }
                                }
                            }
                        }
                        break;
                    default:
                        MapleMapObject ob = mapp.getMapObject(id, MapleMapObjectType.HIRED_MERCHANT);
                        if (ob instanceof IMaplePlayerShop) {
                            IMaplePlayerShop ips = (IMaplePlayerShop) ob;
                            if (ips instanceof HiredMerchant) {
                                merchant = (HiredMerchant) ips;
                            }
                        }
                        break;
                }
                if (merchant != null) {
                    if (merchant.isOwner(c.getPlayer())) {
                        merchant.setOpen(false);
                        merchant.removeAllVisitors(0x14, (byte) 1);
                        c.getPlayer().setPlayerShop(merchant);
                        c.announce(PlayerShopPacket.getHiredMerch(c.getPlayer(), merchant, false));
                    } else if (!merchant.isOpen() || !merchant.isAvailable()) {
                        c.getPlayer().dropMessage(1, "主人正在整理商店物品\r\n请稍后再度光临！");
                    } else if (merchant.getFreeSlot() == -1) {
                        c.getPlayer().dropMessage(1, "店铺已达到最大人数\r\n请稍后再度光临！");
                    } else if (merchant.isInBlackList(c.getPlayer().getName())) {
                        c.getPlayer().dropMessage(1, "你被禁止进入该店铺.");
                    } else {
                        c.getPlayer().setPlayerShop(merchant);
                        merchant.addVisitor(c.getPlayer());
                        c.announce(PlayerShopPacket.getHiredMerch(c.getPlayer(), merchant, false));
                    }
                } else {
                    c.getPlayer().dropMessage(1, "主人正在整理商店物品\r\n请稍后再度光临！");
                }
            }
        }
    }






    public static void PamSong(LittleEndianAccessor slea, MapleClient c) {
        /* 4711 */
        Item pam = c.getPlayer().getInventory(MapleInventoryType.CASH).findById(5640000);
        /* 4712 */
        if (slea.readByte() > 0 && c.getPlayer().getScrolledPosition() != 0 && pam != null && pam.getQuantity() > 0) {
            /* 4713 */
            MapleInventoryType inv = (c.getPlayer().getScrolledPosition() < 0) ? MapleInventoryType.EQUIPPED : MapleInventoryType.EQUIP;
            /* 4714 */
            Item item = c.getPlayer().getInventory(inv).getItem(c.getPlayer().getScrolledPosition());
            /* 4715 */
            c.getPlayer().setScrolledPosition((short) 0);
            /* 4716 */
            if (item != null) {
                /* 4717 */
                Equip eq = (Equip) item;
                /* 4718 */
                eq.setUpgradeSlots((byte) (eq.getUpgradeSlots() + 1));
                /* 4719 */
                c.getPlayer().forceUpdateItem((Item) eq);
                /* 4720 */
                MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.CASH, pam.getPosition(), (short) 1, true, false);
                /* 4721 */
                c.getPlayer().getMap().broadcastMessage(MaplePacketCreator.pamsSongEffect(c.getPlayer().getId()));

            }

        } else {
            /* 4724 */
            c.getPlayer().setScrolledPosition((short) 0);

        }

    }






    public static void TeleRock(LittleEndianAccessor slea, MapleClient c) {
        /* 4732 */
        short slot = slea.readShort();
        /* 4733 */
        int itemId = slea.readInt();
        /* 4734 */
        Item toUse = c.getPlayer().getInventory(MapleInventoryType.USE).getItem(slot);
        /* 4735 */
        if (toUse == null || toUse.getQuantity() < 1 || toUse.getItemId() != itemId || itemId / 10000 != 232 || c.getPlayer().hasBlockedInventory()) {
            /* 4736 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 4739 */
        boolean used = UseTeleRock(slea, c, itemId);
        /* 4740 */
        if (used) {
            /* 4741 */
            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, slot, (short) 1, false);

        }
        /* 4743 */
        c.announce(MaplePacketCreator.enableActions());

    }



    public static boolean UseTeleRock(LittleEndianAccessor slea, MapleClient c, int itemId) {
        /* 4747 */
        boolean used = false;
        /* 4748 */
        if (slea.readByte() == 0) {
            /* 4749 */
            MapleMap target = c.getChannelServer().getMapFactory().getMap(slea.readInt());
            /* 4750 */
            if (((itemId == 5041000 && c.getPlayer().isRockMap(target.getId())) || (itemId != 5041000 && c.getPlayer().isRegRockMap(target.getId())) || ((itemId == 5040004 || itemId == 5041001) && (c.getPlayer().isHyperRockMap(target.getId()) || GameConstants.isHyperTeleMap(target.getId())))) &&
                    /* 4751 */         !FieldLimitType.VipRock.check(c.getPlayer().getMap().getFieldLimit()) && !FieldLimitType.VipRock.check(target.getFieldLimit()) && !c.getPlayer().isInBlockedMap()) {
                /* 4752 */
                c.getPlayer().changeMap(target, target.getPortal(0));
                /* 4753 */
                used = true;

            }

        } else {

            /* 4757 */
            MapleCharacter victim = c.getChannelServer().getPlayerStorage().getCharacterByName(slea.readMapleAsciiString());
            /* 4758 */
            if (victim != null && !victim.isIntern() && c.getPlayer().getEventInstance() == null && victim.getEventInstance() == null) {
                /* 4759 */
                if (!FieldLimitType.VipRock.check(c.getPlayer().getMap().getFieldLimit()) && !FieldLimitType.VipRock.check(c.getChannelServer().getMapFactory().getMap(victim.getMapId()).getFieldLimit()) && !victim.isInBlockedMap() && !c.getPlayer().isInBlockedMap() && (
                        /* 4760 */           itemId == 5041000 || itemId == 5040004 || itemId == 5041001 || victim.getMapId() / 100000000 == c.getPlayer().getMapId() / 100000000)) {
                    /* 4761 */
                    c.getPlayer().changeMap(victim.getMap(), victim.getMap().findClosestPortal(victim.getTruePosition()));
                    /* 4762 */
                    used = true;

                }

            } else {

                /* 4766 */
                c.getPlayer().dropMessage(1, "在此频道未找到该玩家.");

            }

        }
        /* 4769 */
        return used;

    }






    public static void UseNebulite(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 4776 */
        chr.updateTick(slea.readInt());
        /* 4777 */
        chr.setScrolledPosition((short) 0);
        /* 4778 */
        Item nebulite = chr.getInventory(MapleInventoryType.SETUP).getItem(slea.readShort());
        /* 4779 */
        int nebuliteId = slea.readInt();
        /* 4780 */
        Item toMount = chr.getInventory(MapleInventoryType.EQUIP).getItem(slea.readShort());
        /* 4781 */
        if (nebulite == null || nebuliteId != nebulite.getItemId() || toMount == null || chr.hasBlockedInventory()) {
            /* 4782 */
            c.announce(InventoryPacket.getInventoryFull());

            return;

        }
        /* 4785 */
        Equip eqq = (Equip) toMount;
        /* 4786 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /* 4787 */
        boolean success = false;
        /* 4788 */
        if (eqq.getSocketState() != 0) {
            /* 4789 */
            StructItemOption pot = ii.getSocketInfo(nebuliteId);
            /* 4790 */
            if (pot != null && GameConstants.optionTypeFits(pot.optionType, eqq.getItemId())) {
                /* 4791 */
                success = true;
                /* 4792 */
                if (eqq.getSocket1() == 0) {
                    /* 4793 */
                    eqq.setSocket1(pot.opID);
                    /* 4794 */
                } else if (eqq.getSocket2() == 0) {
                    /* 4795 */
                    eqq.setSocket2(pot.opID);
                    /* 4796 */
                } else if (eqq.getSocket3() == 0) {
                    /* 4797 */
                    eqq.setSocket3(pot.opID);

                } else {
                    /* 4799 */
                    success = false;

                }

            }
            /* 4802 */
            if (success) {
                /* 4803 */
                MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.SETUP, nebulite.getPosition(), (short) 1, false);
                /* 4804 */
                chr.forceUpdateItem(toMount);

            }

        }
        /* 4807 */
        chr.getMap().broadcastMessage(InventoryPacket.showNebuliteEffect(c.getPlayer().getId(), success, success ? "成功嵌入星岩。" : "嵌入星岩失败。"));
        /* 4808 */
        c.announce(MaplePacketCreator.enableActions());

    }






    public static void UseAdditionalAddItem(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 4815 */
        if (chr == null || !chr.isAlive() || chr.getMap() == null || chr.hasBlockedInventory() || chr.inPVP()) {
            /* 4816 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 4819 */
        chr.updateTick(slea.readInt());
        /* 4820 */
        short slot = slea.readShort();
        /* 4821 */
        short toSlot = slea.readShort();
        /* 4822 */
        Item scroll = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /* 4823 */
        Equip toScroll = (Equip) chr.getInventory(MapleInventoryType.EQUIP).getItem(toSlot);
        /* 4824 */
        if (scroll == null || scroll.getQuantity() < 0 || !ItemConstants.isSealAddItem(scroll.getItemId()) || toScroll == null || toScroll.getQuantity() != 1) {
            /* 4825 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 4828 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /* 4829 */
        int successRate = ii.getScrollSuccess(scroll.getItemId());
        /* 4830 */
        boolean noCursed = ii.isNoCursedScroll(scroll.getItemId());
        /* 4831 */
        if (successRate <= 0) {
            /* 4832 */
            c.getPlayer().dropMessage(1, "卷轴道具: " + scroll.getItemId() + " - " + ii.getName(scroll.getItemId()) + " 成功几率为: " + successRate + " 该卷轴可能还未修复.");
            /* 4833 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 4836 */
        if (chr.isAdmin()) {
            /* 4837 */
            chr.dropSpouseMessage(11, "卷轴道具: " + scroll.getItemId() + " - " + ii.getName(scroll.getItemId()) + " 成功几率为: " + successRate + "% 卷轴是否失败不消失装备: " + noCursed);

        }
        /* 4839 */
        if (toScroll.getPotential(1, true) == 0 || toScroll.getPotential(2, true) == 0 || toScroll.getPotential(3, true) == 0) {
            /* 4840 */
            boolean success = false;
            /* 4841 */
            int lines = (toScroll.getPotential(1, true) == 0) ? 4 : ((toScroll.getPotential(2, true) == 0) ? 5 : 6);
            /* 4842 */
            int reqLevel = ii.getReqLevel(toScroll.getItemId()) / 10;
            /* 4843 */
            int rank = (reqLevel >= 20) ? 19 : reqLevel;
            /* 4844 */
            if (Randomizer.nextInt(100) <= successRate) {

                /* 4846 */
                List<List<StructItemOption>> pots = ii.getFilterPotentials();
                /* 4847 */
                boolean rewarded = false;
                /* 4848 */
                while (!rewarded) {
                    /* 4849 */
                    StructItemOption option = ((List<StructItemOption>) pots.get(Randomizer.nextInt(pots.size()))).get(rank);
                    /* 4850 */
                    if (option != null && !GameConstants.isAboveA(option.opID) && option.reqLevel / 10 <= rank && GameConstants.optionTypeFits(option.optionType, toScroll.getItemId()) && GameConstants.potentialIDFits(option.opID, 17, 1) && GameConstants.isBlockedPotential(toScroll, option.opID, true, false)) {
                        /* 4851 */
                        toScroll.setPotential(option.opID, lines - 3, true);
                        /* 4852 */
                        if (chr.isShowPacket()) {
                            /* 4853 */
                            chr.dropMessage(5, "附加潜能" + lines + " 获得ID： " + option.opID);

                        }
                        /* 4855 */
                        rewarded = true;

                    }

                }
                /* 4858 */
                success = true;

            }





            /* 4865 */
            toScroll.initAllState();
            /* 4866 */
            List<ModifyInventory> mods = new ArrayList<>();
            /* 4867 */
            boolean removeItem = false;
            /* 4868 */
            mods.add(new ModifyInventory(3, (Item) toScroll));
            /* 4869 */
            if (!success && !noCursed) {
                /* 4870 */
                if (ItemFlag.装备防爆.check(toScroll.getFlag())) {
                    /* 4871 */
                    chr.dropSpouseMessage(11, "由于卷轴的效果，物品没有损坏。");
                    /* 4872 */
                    toScroll.removeFlag((short) ItemFlag.装备防爆.getValue());
                    /* 4873 */
                    mods.add(new ModifyInventory(3, (Item) toScroll));

                } else {
                    /* 4875 */
                    removeItem = true;
                    /* 4876 */
                    chr.getInventory(MapleInventoryType.EQUIP).removeItem(toScroll.getPosition());

                }

            }
            /* 4879 */
            if (ItemFlag.装备防爆.check(toScroll.getFlag())) {
                /* 4880 */
                toScroll.removeFlag((short) ItemFlag.装备防爆.getValue());

            }
            /* 4882 */
            if (!removeItem) {
                /* 4883 */
                mods.add(new ModifyInventory(0, (Item) toScroll));

            }
            /* 4885 */
            c.announce(InventoryPacket.modifyInventory(true, mods, chr));
            /* 4886 */
            chr.getMap().broadcastMessage(InventoryPacket.潜能扩展效果(chr.getId(), success, scroll.getItemId(), removeItem));
            /* 4887 */
            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, scroll.getPosition(), (short) 1, false);

        } else {
            /* 4889 */
            c.announce(MaplePacketCreator.enableActions());

        }

    }



    public static void UseAdditionalItem(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 4894 */
        if (chr == null || !chr.isAlive() || chr.getMap() == null || chr.hasBlockedInventory() || chr.inPVP()) {
            /* 4895 */
            c.sendEnableActions();

            return;

        }
        /* 4898 */
        chr.updateTick(slea.readInt());
        /* 4899 */
        short slot = slea.readShort();
        /* 4900 */
        short toSlot = slea.readShort();
        /* 4901 */
        Item scroll = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /* 4902 */
        Equip toScroll = (Equip) chr.getInventory((toSlot < 0) ? MapleInventoryType.EQUIPPED : MapleInventoryType.EQUIP).getItem(toSlot);
        /* 4903 */
        if (scroll == null || scroll.getQuantity() < 0 || !ItemConstants.isSealItem(scroll.getItemId()) || toScroll == null || toScroll.getQuantity() != 1) {
            /* 4904 */
            c.sendEnableActions();

            return;

        }
        /* 4907 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /* 4908 */
        int successRate = ii.getScrollSuccess(scroll.getItemId());
        /* 4909 */
        if (successRate <= 0) {
            /* 4910 */
            c.getPlayer().dropMessage(1, "卷轴道具: " + scroll.getItemId() + " - " + ii.getName(scroll.getItemId()) + " 成功几率为: " + successRate + " 该卷轴可能还未修复.");
            /* 4911 */
            c.sendEnableActions();

            return;

        }
        /* 4914 */
        if (chr.isAdmin()) {
            /* 4915 */
            chr.dropSpouseMessage(11, "卷轴道具: " + scroll.getItemId() + " - " + ii.getName(scroll.getItemId()) + " 成功几率为: " + successRate + "%");

        }
        /* 4917 */
        if (toScroll.getPotential(1, false) == 0 || toScroll.getPotential(2, false) == 0 || toScroll.getPotential(3, false) == 0) {
            /* 4918 */
            boolean success = false;
            /* 4919 */
            int lines = (toScroll.getPotential(2, false) == 0) ? 2 : ((toScroll.getPotential(1, false) == 0) ? 1 : 3);
            /* 4920 */
            int reqLevel = ii.getReqLevel(toScroll.getItemId()) / 10;
            /* 4921 */
            int rank = (reqLevel >= 20) ? 19 : reqLevel;
            /* 4922 */
            if (Randomizer.nextInt(100) <= successRate) {

                /* 4924 */
                List<List<StructItemOption>> pots = ii.getFilterPotentials();
                /* 4925 */
                boolean rewarded = false;
                /* 4926 */
                while (!rewarded) {
                    /* 4927 */
                    StructItemOption option = ((List<StructItemOption>) pots.get(Randomizer.nextInt(pots.size()))).get(rank);
                    /* 4928 */
                    if (option != null && !GameConstants.isAboveA(option.opID) && option.reqLevel / 10 <= rank && GameConstants.optionTypeFits(option.optionType, toScroll.getItemId()) && GameConstants.potentialIDFits(option.opID, 17, 1) && GameConstants.isBlockedPotential(toScroll, option.opID, false, false)) {
                        /* 4929 */
                        toScroll.setPotential(option.opID, lines, false);
                        /* 4930 */
                        if (chr.isAdmin()) {
                            /* 4931 */
                            chr.dropMessage(5, "印章潜能" + lines + " 获得ID： " + option.opID);

                        }
                        /* 4933 */
                        rewarded = true;

                    }

                }
                /* 4936 */
                if (ItemConstants.isZeroWeapon(toScroll.getItemId())) {
                    /* 4937 */
                    chr.forceUpdateItem((Item) ((Equip) chr.getInventory(MapleInventoryType.EQUIPPED).getItem((short) ((toSlot == -10) ? -11 : -10))).copyPotential(toScroll), true);

                }
                /* 4939 */
                success = true;

            }
            /* 4941 */
            toScroll.initAllState();
            /* 4942 */
            List<ModifyInventory> mods = new ArrayList<>();
            /* 4943 */
            mods.add(new ModifyInventory(3, (Item) toScroll));
            /* 4944 */
            mods.add(new ModifyInventory(0, (Item) toScroll));
            /* 4945 */
            c.announce(InventoryPacket.modifyInventory(true, mods, chr));
            /* 4946 */
            chr.getMap().broadcastMessage(InventoryPacket.潜能扩展效果(chr.getId(), success, scroll.getItemId(), false));
            /* 4947 */
            MapleInventoryManipulator.removeFromSlot(c, MapleInventoryType.USE, scroll.getPosition(), (short) 1, false);

        } else {
            /* 4949 */
            c.sendEnableActions();

        }

    }






    public static void BuyCrossHunterItem(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 4957 */
        if (chr == null || !chr.isAlive() || chr.getMap() == null || chr.hasBlockedInventory() || chr.inPVP()) {
            /* 4958 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 4961 */
        int key = slea.readShort();
        /* 4962 */
        int itemId = slea.readInt();
        /* 4963 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /* 4964 */
        StructCrossHunterShop shop = ii.getCrossHunterShop(key);
        /* 4965 */
        if (shop != null && itemId == shop.getItemId() && shop.getTokenPrice() > 0) {
            /* 4966 */
            if (chr.getInventory(MapleInventoryType.ETC).countById(4310029) >= shop.getTokenPrice()) {
                /* 4967 */
                if (MapleInventoryManipulator.checkSpace(c, shop.getItemId(), 1, "")) {
                    /* 4968 */
                    MapleInventoryManipulator.removeById(c, MapleInventoryType.ETC, 4310029, shop.getTokenPrice(), true, false);
                    /* 4969 */
                    MapleInventoryManipulator.addById(c, shop.getItemId(), (short) 1, shop.getPotentialGrade(), "十字商店购买: " + DateUtil.getCurrentDate());
                    /* 4970 */
                    c.announce(MaplePacketCreator.confirmCrossHunter((byte) 0));

                } else {
                    /* 4972 */
                    c.announce(MaplePacketCreator.confirmCrossHunter((byte) 2));

                }

            } else {
                /* 4975 */
                c.announce(MaplePacketCreator.confirmCrossHunter((byte) 1));

            }

        } else {
            /* 4978 */
            c.announce(MaplePacketCreator.confirmCrossHunter((byte) 4));

        }

    }


    public static void UseSoulScroll(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {

        int pot;
        /* 4983 */
        c.getPlayer().updateTick(slea.readInt());
        /* 4984 */
        short slot = slea.readShort();
        /* 4985 */
        short toSlot = slea.readShort();
        /* 4986 */
        Item scroll = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /* 4987 */
        Equip equip = (Equip) chr.getInventory(MapleInventoryType.EQUIPPED).getItem(toSlot);

        /* 4989 */
        if (equip == null || scroll == null) {
            /* 4990 */
            c.announce(MaplePacketCreator.enableActions());


            return;

        }
        /* 4994 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /* 4995 */
        int soulid = scroll.getItemId();
        /* 4996 */
        int skillid = ii.getSoulSkill(soulid);
        /* 4997 */
        if (skillid == 0 || equip.getSoulEnchanter() == 0) {
            /* 4998 */
            c.announce(MaplePacketCreator.enableActions());


            return;

        }
        /* 5002 */
        ArrayList<Integer> tempOption = ii.getTempOption(soulid);

        /* 5004 */
        if (tempOption.isEmpty()) {
            /* 5005 */
            c.announce(MaplePacketCreator.enableActions());
            return;

        }
        /* 5007 */
        if (tempOption.size() == 1) {
            /* 5008 */
            pot = ((Integer) tempOption.get(0)).intValue();

        } else {
            /* 5010 */
            pot = ((Integer) tempOption.get(Randomizer.nextInt(tempOption.size()))).intValue();

        }

        /* 5013 */
        int success = ii.getScrollSuccess(scroll.getItemId(), 100);

        /* 5015 */
        chr.getInventory(ItemConstants.getInventoryType(scroll.getItemId())).removeItem(scroll.getPosition(), (short) 1, false);
        /* 5016 */
        List<ModifyInventory> mods = new ArrayList<>();
        /* 5017 */
        mods.add(new ModifyInventory((scroll.getQuantity() > 0) ? 1 : 3, scroll));

        /* 5019 */
        if (Randomizer.nextInt(100) < success) {
            /* 5020 */
            int skid = chr.getEquippedSoulSkill();
            /* 5021 */
            if (skid > 0) {
                /* 5022 */
                chr.changeSkillLevel(new Skill(chr.getEquippedSoulSkill()), (byte) 0, (byte) 0);

            }
            /* 5024 */
            chr.setSoulCount((short) 0);
            /* 5025 */
            equip.setSoulName((short) (soulid % 1000 + 1));
            /* 5026 */
            equip.setSoulPotential((short) pot);
            /* 5027 */
            equip.setSoulSkill(skillid);
            /* 5028 */
            chr.changeSkillLevel(new Skill(skillid), (byte) 1, (byte) 1);
            /* 5029 */
            chr.getMap().broadcastMessage(chr, MaplePacketCreator.showSoulScrollEffect(chr.getId(), true, false), true);
            /* 5030 */
            mods.add(new ModifyInventory(3, (Item) equip));
            /* 5031 */
            mods.add(new ModifyInventory(0, (Item) equip));

        } else {
            /* 5033 */
            chr.getMap().broadcastMessage(chr, MaplePacketCreator.showSoulScrollEffect(chr.getId(), false, false), true);

        }
        /* 5035 */
        c.announce(InventoryPacket.modifyInventory(true, mods, chr));

    }



    public static void UseSoulEnchanter(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 5039 */
        if (chr == null || !chr.isAlive() || chr.getMap() == null || chr.hasBlockedInventory() || chr.inPVP()) {
            /* 5040 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 5043 */
        chr.updateTick(slea.readInt());
        /* 5044 */
        short slot = slea.readShort();
        /* 5045 */
        short toSlot = slea.readShort();
        /* 5046 */
        Item scroll = chr.getInventory(MapleInventoryType.USE).getItem(slot);
        /* 5047 */
        Equip nEquip = (Equip) chr.getInventory(MapleInventoryType.EQUIPPED).getItem(toSlot);
        /* 5048 */
        if (nEquip == null || scroll == null) {
            /* 5049 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 5052 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();

        /* 5054 */
        int reqLevel = ii.getReqLevel(nEquip.getItemId());
        /* 5055 */
        Pair<Integer, Integer> socketReqLevel = ii.getSocketReqLevel(scroll.getItemId());
        /* 5056 */
        if (reqLevel > ((Integer) socketReqLevel.getLeft()).intValue() || reqLevel < ((Integer) socketReqLevel.getRight()).intValue()) {
            /* 5057 */
            chr.dropMessage(-1, "无法使用该道具！");
            /* 5058 */
            c.announce(MaplePacketCreator.enableActions());


            return;

        }
        /* 5062 */
        int success = ii.getScrollSuccess(scroll.getItemId(), 100);
        /* 5063 */
        List<ModifyInventory> mods = new ArrayList<>();
        /* 5064 */
        if (Randomizer.nextInt(100) <= success) {
            /* 5065 */
            nEquip.setSoulName((short) 1);
            /* 5066 */
            nEquip.setSoulEnchanter((short) 3);
            /* 5067 */
            chr.getMap().broadcastMessage(chr, MaplePacketCreator.showEnchanterEffect(chr.getId(), true), true);
            /* 5068 */
            c.announce(BuffPacket.show灵魂武器(nEquip.getSoulSkill(), 0));

        } else {
            /* 5070 */
            chr.getMap().broadcastMessage(chr, MaplePacketCreator.showEnchanterEffect(chr.getId(), false), true);

        }
        /* 5072 */
        chr.getInventory(ItemConstants.getInventoryType(scroll.getItemId())).removeItem(scroll.getPosition(), (short) 1, false);
        /* 5073 */
        mods.add(new ModifyInventory((scroll.getQuantity() > 0) ? 1 : 3, scroll));
        /* 5074 */
        mods.add(new ModifyInventory(3, (Item) nEquip));
        /* 5075 */
        mods.add(new ModifyInventory(0, (Item) nEquip));
        /* 5076 */
        c.announce(InventoryPacket.modifyInventory(true, mods, chr));

        /* 5078 */
        c.announce(MaplePacketCreator.enableActions());

    }



    public static void applyHyunCube(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 5082 */
        chr.updateTick(slea.readInt());
        /* 5083 */
        int int1 = slea.readInt();
        /* 5084 */
        if (chr.getOneInfo(52998, "dst") != null) {
            /* 5085 */
            int intValue = Integer.valueOf(chr.getOneInfo(52998, "dst")).intValue();
            /* 5086 */
            Equip equip = (Equip) chr.getInventory((intValue > 0) ? MapleInventoryType.EQUIP : MapleInventoryType.EQUIPPED).getItem((short) intValue);
            /* 5087 */
            if (equip != null) {
                /* 5088 */
                for (int i = 1; i <= int1; i++) {
                    /* 5089 */
                    equip.setPotential(slea.readInt(), i, false);

                }
                /* 5091 */
                equip.setState((byte) (16 + equip.getState(false)), false);
                /* 5092 */
                chr.forceUpdateItem((Item) equip, true);
                /* 5093 */
                chr.send(InventoryPacket.showHyunPotentialResult(true, 0, null));
                /* 5094 */
                chr.removeInfoQuest(52998);
                /* 5095 */
                chr.equipChanged();

            } else {
                /* 5097 */
                chr.dropMessage(1, "没有获取到装备.");

            }

        } else {
            /* 5100 */
            chr.send(InventoryPacket.showHyunPotentialResult(true, 0, null));

        }
        /* 5102 */
        c.sendEnableActions();

    }





    public static void applyBlackCube(LittleEndianAccessor slea, MapleClient c, MapleCharacter chr) {
        /* 5108 */
        if (chr == null || !chr.isAlive() || chr.getMap() == null || chr.hasBlockedInventory() || chr.inPVP()) {
            /* 5109 */
            c.announce(MaplePacketCreator.enableActions());

            return;

        }
        /* 5112 */
        chr.updateTick(slea.readInt());
        /* 5113 */
        int mode = slea.readShort();

        /* 5115 */
        if (mode != 7 && chr.getOneInfo(52889, "dst") != null) {
            /* 5116 */
            boolean b = (Integer.valueOf(chr.getOneInfo(52889, "add")).intValue() == 1);
            /* 5117 */
            int intValue = Integer.valueOf(chr.getOneInfo(52889, "dst")).intValue();
            /* 5118 */
            Equip nEquip = (Equip) chr.getInventory((intValue > 0) ? MapleInventoryType.EQUIP : MapleInventoryType.EQUIPPED).getItem((short) intValue);
            /* 5119 */
            for (int i = 0; i < 3; i++) {
                /* 5120 */
                if (chr.getOneInfo(52889, "Pot" + i) != null) {
                    /* 5121 */
                    nEquip.setPotential(Integer.valueOf(chr.getOneInfo(52889, "Pot" + i)).intValue(), i + 1, b);

                }

            }
            /* 5124 */
            nEquip.initAllState();
            /* 5125 */
            chr.equipChanged();
            /* 5126 */
            chr.forceUpdateItem((Item) nEquip);
            /* 5127 */
            chr.removeInfoQuest(52889);

        }

        /* 5130 */
        chr.resetItemPotential();
        /* 5131 */
        c.announce(InventoryPacket.showBlackCubeResults());

    }








    public static void UseFamiliarCard(MapleCharacter chr) {
        /* 5140 */
        MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
        /* 5141 */
        int maxGrade = 3;
        /* 5142 */
        List<Integer> cards = ii.getRandomFamiliarCard(maxGrade);
        /* 5143 */
        Map<Integer, Integer> familiarids = new LinkedHashMap<>();
        /* 5144 */
        maxGrade++;
        /* 5145 */
        for (Integer integer : cards) {
            /* 5146 */
            int random = Randomizer.nextInt(1000);

            /* 5148 */
            int grade = chr.isAdmin() ? maxGrade-- : ((Randomizer.nextInt(1000) < 50) ? 3 : ((50 <= random && random < 300) ? 2 : ((300 <= random && random < 750) ? 1 : 0)));
            /* 5149 */
            int familiarid = ii.getFamiliarID(integer.intValue());
            /* 5150 */
            familiarids.put(Integer.valueOf(familiarid), Integer.valueOf(grade));
            /* 5151 */
            Item item = new Item(integer.intValue(), (short) 0, (short) 1);
            /* 5152 */
            item.setFamiliarCard(new FamiliarCard((byte) grade));
            /* 5153 */
            item.setGMLog("使用怪怪卡牌包获得");
            /* 5154 */
            MapleInventoryManipulator.addbyItem(chr.getClient(), item);

        }
        /* 5156 */
        chr.send(FamiliarPacket.ShowFamiliarCardBag(chr.getId(), (byte) 5, 2, (short) 4, familiarids));

    }

}


/* Location:              C:\PGX\Server.jar!\handling\channel\handler\InventoryHandler.class
 * Java compiler version: 8 (52.0)
 * JD-Core Version:       1.1.3
 */